How to convert excel column data into array and each value separated with ;

Hi Team,
I have one excel and I want to extract the B column data and stored into array of string and each group name separated with ; using UiPath.

Can any one help me to solve the issue.


Attaching is the screenshot for your reference.
Kindly suggest.

Output like this : {A411058;A096876;A107040 etc…}

Regards,
baby

we assume that the excel was read in into datatable (e.g. read range) - dtData

Assign Activity
arrValues | String Array =
dtData.AsEnumerable.Select(Function (x) x("Group Name").toString.Trim).toArray

Assign Activity
strFlatValues = String.Join(";",arrValues)

Hi @Baby123

Try this query

 columnBValues= (From row In dt.AsEnumerable()
                                  Select row.Field(Of String)("column name")).ToArray()

resultString = String.Join(";", columnBValues)

Note columnBValues is of DataType Array(System.String)

Hope it helps!!

Hi @Baby123

Input:

Query:

Assign activity -> Output= (From row In dtInput.AsEnumerable()
                                  Select row.Field(Of String)("Group Number")).ToArray()

Message Box -> String.Join("; ",Output)

Output is of DataType Array(System.String)

Output:

Regards

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