Application Development and Automation 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: 
Read only

Problem while opening Excel through OLE

praveen_hannu
Contributor
0 Likes
308

Hi Friends

I am facing a problem while opening an excel file through OLE. it is working fine in SAP ECC 5.0, but the problem is in ECC 6.0.

I am adjusting the cells for auto fit. I have written the code like below.

CALL METHOD OF e_appl 'CELLS' = e_cell.

CALL METHOD OF e_cell 'EntireColumn' = ole_columns .

CALL METHOD OF ole_columns 'AutoFit'.

set property of e_appl 'VISIBLE' = 1.

if I take out the adjustment part it is working fine for this program, rest other programs even if I have this code, they working fine.

When I am executing the statement set property of e_appl 'VISIBLE' = 1. the return code is coming as 2.

Could anybody please help me to overcome this problem.

Thanks

Praveen

1 REPLY 1
Read only

praveen_hannu
Contributor
0 Likes
282

In ECC 6.0, if the worksheet is portedcted SAP unable to open that sheet, now we have taken out this option so it is working.