Lesson-9 practice-1

Hii everyone,

what does this mean?
valueA=row(0).ToString
valueB=row(1).ToString
row(2)=Integer.Parse(valueA) + Integer.Parse(valueB)
and how thw data will be stored in column c in excel

Thanks and Regards
Supriya

2 Likes

Hi,

Parse is converting string to integer and add the both integer value then stores the values in row(2)–column c

Hi,

row(0) gets the data from the selected 0th element of the array/datatable/list
ValueA=row(0).ToString - Converts the value in that position to string and assigns it to ValueA

Sale is with

What happens here is as follows.
Integer.Parse(ValueA) - This will actually convert the value in ‘ValueA’ variable into an integer…
Integer.Parse(valueA) + Integer.Parse(valueB) - Converts both values in variables ValueA and ValueB into an integer and adds them together and assigns it to the 3rd row.

Hi :slight_smile:

Got it …

Thanks and regards,
Supriya

1 Like