Delete specific column

i want to delete specific column from excel sheet by using their header

hi,
lets assume your datatable is dtTable1, please try this

{dtTable1.Columns(2).ColumnName.ToString,dtTable1.Columns(3).ColumnName.ToString,dtTable1.Columns(4).ColumnName.ToString,dtTable1.Columns(5).ColumnName.ToString}

give this in the column names

mark as solution if it is useful , lets other take advantage

happy automation …!!!

Hi @pravin_bindage

https://docs.uipath.com/lang-ru/activities/docs/delete-column-x
Delete column activity can be used to delete column from excel sheet

if we use that activity then what can i write in table name field?

Delete column activity from excel application scope activities.


input - position
i wants to delete column based on header name

Use excel process scope and use excel file activity inside the delete column activity should be used.These are workbook activity.I am talking about excel activity

Hi @pravin_bindage

To remove specific column in Datatable then use “Remove Data column” activity by mentioning column name or column index.

image

thanks!

1 Like

i’m using excel activities not workbook
& activity is inside excel scope
workbook dont have this activity

https://images.app.goo.gl/S1Mysj6jpqvum


I am talking about the above activity

@pravin_bindage

Delete column is a modern activity …please check from activities → filter incon if the show modern option is checked or not…

Then you can view modern activities

Cheers

1 Like

Hi @pravin_bindage
You can use the Delete column activity to delete a column in a datatable.

image

Refer this Link:

Regards,
Kaviyarasu N