Solved

Add character comma in number

  • 20 November 2023
  • 3 replies
  • 53 views

Hi All,

How we can add comma(,) in between the numbers.

Scenario: I have two numbers to verify. To verify below 2 numbers, how we can add comma in between the numbers. (Note: Number length is not fix)

Number 1: $144,653 (Not editable)

Number 2: 144653 editable.

 

icon

Best answer by Harish N 7 December 2023, 03:32

View original

3 replies

Userlevel 2
Badge

Hi Vivek,

Please find the below kb for the same.

https://support-hub.tricentis.com/open?id=kb_article_view&sys_kb_id=c421a8a51bb82414e07e20a1b24bcbff

The above requires excel to be installed in the vm.

Thanks,

Harish N

Userlevel 2
Badge

Assuming you are first getting number 1 in your test case and then need to verify number 2 has the same value:

For Number 1, I would buffer the value without the $, i.e. action mode Verify and value ${XB[yourbuffername]} in the test step.

For Number 2, action mode Verify, value {B[yourbuffername]} and data type Numeric (instead of the default String).

Using the Numeric data type can solve most number formatting problems like this one without resorting to more complex string manipulation.

Hi All,

How we can add comma(,) in between the numbers.

Scenario: I have two numbers to verify. To verify below 2 numbers, how we can add comma in between the numbers. (Note: Number length is not fix)

Number 1: $144,653 (Not editable)

Number 2: 144653 editable.

 

Hi, 
You can use TBox Convert Decimal Standard module to get the desired result.
Here is the link - Search Result - Tricentis Support

Thank you.

Reply