//open excel,f_path is path for the file
form run_excel using f_path.
data: application type ole2_object, "OLE Object for ExcelApplication
workbook type ole2_object. "OLE Object for ExcelWorkbook
create object application 'EXCEL.APPLICATION'.
set property of application 'visible' = 1.
call method of application 'Workbooks' = workbook.
call method of workbook 'Open'
exporting #1 = f_path.
free object application.
endform.
form run_excel using f_path.
data: application type ole2_object, "OLE Object for ExcelApplication
workbook type ole2_object. "OLE Object for ExcelWorkbook
create object application 'EXCEL.APPLICATION'.
set property of application 'visible' = 1.
call method of application 'Workbooks' = workbook.
call method of workbook 'Open'
exporting #1 = f_path.
free object application.
endform.

