Copy values of particular column and paste the column values all at a time in SAP

Hi,

I have to copy the values of a particular column in excel and paste them into sap all at a time. I used send hotkeys activity to do this but i am not sure if it is good approach to select the entire column and paste them into SAP. Can anyone suggest any other alternative to get the values of a column and paste them to SAP all at a time.

You don’t copy/paste. Use the Excel activities to read the data into a datatable.

how to read particular column values only. If we use read column activity, output is IEnumberable type due to which i am not able to convert it into text

Use read range activity and you will get a datatable variable as output

can we pass that text to clipboard?

You can convert the datatable to text using output datatable activity and pass to clipboard

but to use read range activity, i need to give cell range. in my case cell range changes daily

Ok so can you just confirm me that , are you trying to get a single value at a time from a specific column and trying to paste it in sap ? or you are taking a bunch of values ?

You dont need to give the full range , you can give just the starting cell , rest it will take up automatically

For eg: if you give cell address as A1:B3 it will take up to b3, if you dont know the ending cell you can give as A1 itself,

i am taking entire column values

can you share a screen shot of the excel and column values you are trying to pick
?

i need to select range of only particular column…lets say reqired column values are in Column “E”. i need to take only values from “E1” to “E23” where 23 is last row. but here number of rows changes daily.

Why are you trying to copy/paste? That’s not how you do things. You use activities like type into, set text, etc

hi @Sirisha_Siri
you can use these 2 custom activities to achieve that

  1. use Convert DT column to HTML to convert the whole excel column to text file
    Column to HTML - RPA Component | UiPath Marketplace

use Import Text File to SAP List to upload the contents of text file contents to SAP

for example of Import Text File to SAP List please refer to the below video

even if you dont use my package, you dont have to copy and paste . Because in the SAP multiple selection screen theres an upload text file button you can use to upload the contents of a text file to SAP

theres no need to copy/paste or type anything apart from the path of the text file

1 Like


i need to get all the values in column G and pass it to clipboard as a text. number of rows in column G changes daily. there are other columns as well in excel…but i need only column g values

Sorry i was not supposed to install any other packages.

ya, in sap i know that it can be pasted in single click…but before that i need to get entire column values as text.

Read Range to get the column into a datatable then For Each Row in Datatable and concatenate the values into a string variable.

while using read range activity, how can i get values of only paticular column. i need to give the range in read range activity and the number of rows will get changed daily. can u pls let me know how to give range here

You specify that column as the range, for example B2:B50

But it doesn’t really matter. You could read the entire spreadsheet and then only use the column you want from the datatable.