Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

problem on paste data from clipboard to excel sheet

0 Kudos
511

Hello,

I'm using the following code to set excel sheet with internal table data .

the problem is with the "paste" command - the sheet remains empty .

The process was ok until recently , so i suspect that there was an upgrade on office or windows...

Thank you .



CALL METHOD cl_gui_frontend_services=>clipboard_export

IMPORTING

data = it_sheet[]

CHANGING

rc = l_rc

EXCEPTIONS

cntl_error = 1

error_no_gui = 2

not_supported_by_gui = 3

OTHERS = 4.

CALL METHOD OF h_excel 'Cells' = w_cell1

EXPORTING

#1 = 1

#2 = 1.

CALL METHOD OF h_excel 'Cells' = w_cell2

EXPORTING

#1 = 1

#2 = 1.

CALL METHOD OF h_excel 'Range' = range

EXPORTING

#1 = w_cell1

#2 = w_cell2.

CALL METHOD OF range 'Select'.

CALL METHOD OF worksheet 'Paste'.



2 REPLIES 2

RRA
Explorer
0 Kudos
338

Hi Kobi,

Did you find a solution for this? I'm experiencing the same problem. my excel version is 2209.

hermanfish
Newcomer
0 Kudos
128

any update?