Data Table convert to single string and Split the Data

I have a dataTable I have to Split the Row values and get them in following Format.

DT Values :

Expected Format : Single String
item 1 is - Car ; item 2 is - Mobile ; item 3 is : House

and need to write in Excel, e.g “A1”

Any help idea would be appreciated.


I read many of your Post and they were very helpful for me, while I was learning.

Can you please help me with this, your guidance would be appreciated.


Hey @Gagan_Chaudhari

Yep, that’s possible. I just mimicked the entire string you showed not sure whether you need that item :sweat_smile:

String.Join(";",dtData.AsEnumerable.Select(Function(row, index) "item " + CStr(index+1) + " is - " + row(0).ToString))

Also do you want to write it in only in one Excel cell all the values of the DT right ?

Kindly try this.


Hey ,
I alter some part of it and It’s working,

Thanks a lot :slight_smile:

Cool buddy great :slightly_smiling_face::+1:

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.