How can I write one column from a datatable which has some columns to an Excel file .
Like this picture.xlsx (43.6 KB)
@oitot, directly use this query in write range, if you want distinct elements from that column
datatable.DefaultView.ToTable(True,“Column Name”)
If you want all values (including duplicate) make that true to false !
Regards,
Dominic
HI Dominic
I used “datatable.DefaultView.ToTable(False,“Column Name”)”. It worked !
Thanks so mush!!!
Hi Bharat.
Thanks ,it worked !
Hey @ravi007teja @MariaJosephina,
The .ToTable
function accepts two arguments (also there are other overloads) which is Boolean & String()
The above example shows how to list the column names as an array. If you would like to add the column index then you can write a small snippet that will convert the array of column index that you have given into the array of column name that can be used.
Very neat - thanks Dominic.
Thanks Bro. Saved lot of time.
hi please aider write cell