hii,
I have one keyword based on that i want to extract the column index of that particular keyword.
please help
hii,
I have one keyword based on that i want to extract the column index of that particular keyword.
please help
Can you elaborate your question? What is the relationship between your keyword and column name/index?
I want to just fetch the column index where these keyword present
Hey @Doonline
The below will fetch you the column index of the matched keyword from the datatable.
dt_master.AsEnumerable.Where(Function(row) row.ItemArray.Contains("keyword")).First().ItemArray.IndexOf("keyword")
The above statement has,
It will first identify the row in which the keyword is present
Then It will identify the column index from that row which has the keyword
Hope this helps
Thanks
#nK
Hi @Doonline ,
There are many methods in which we can get the Column Index of a Particular Keyword from a Datatable.
Although it may not be certain of the Keyword uniqueness, the below workflow will retrieve the Column Index of the Keyword of it’s First Match while searching the rows.
Check the below workflow having an Example and Let us know if it doesn’t work or need an alternate solution.
Get_ColumnIndex_OnKeyword.xaml (9.3 KB)
we would recommend to have a more specific requirements also handling e.g.
Have a look on following flow, generating a report on the different occurrences:
find starter help here:
GetAllRowColIdx_By1Value.xaml (10.7 KB)