Forum Discussion

trajmo's avatar
trajmo
Occasional Contributor
6 years ago
Solved

Format for numeric value

Hello,

I am trying to specify a property checkpoint for my fild which contains numbers, to check the format, in the code of my desktop application in Delphi is specified #,##0.00, how can i do it with the same format to be checked in my keyword.

Thanks,

8 Replies

    • trajmo's avatar
      trajmo
      Occasional Contributor

      Thanks for your quick response.

      I am still trying to resolve my issue, i read all the articles for aqString.Format method but i cannot figure out how to do it. I am sending the printscreens of my error and my property check point expression.

      For sure i am wrong somewhere.

      In my code of the application the format in Delphi is specified by '#,##0.00'

      But i dont know how to do it in TC.

       

      • tristaanogre's avatar
        tristaanogre
        Esteemed Contributor

        Well, for one thing, the "Property" field should be the field that indicates which property of the object you're going to do a check against... you don't put the "aqString.Format" code in there....

        So... you're doing a property checkpoint... meaning you want to check that the value of a property matches an expected value.  So...  in your checkpoint, the "Object" field should be everything all the way up to but NOT including the "wText"... that should be set up as an "Onscreen Object".   The "Property" field should be a string containng "wText".

         

        It's the "Value" field where it sounds like you want to use the Code Expression for "aqString.Format".  Basically, this is where you're going to put in the value that you want to compare... 

        Start with that...