Assuming you have created the Excel application object as V_EXCEL...
DATA: V_CRANGE TYPE OLE2_OBJECT, V_FONT TYPE OLE2_OBJECT. ... * Set font for Column F CALL METHOD OF V_EXCEL 'Range' = V_CRANGE EXPORTING #1 = 'F:F'. CALL METHOD OF V_CRANGE 'Select'. GET PROPERTY OF V_CRANGE 'font' = V_FONT. SET PROPERTY OF V_FONT 'SIZE' = 11. SET PROPERTY OF V_FONT 'NAME' = 'Arial'. * Set font for Row 5 - 8 CALL METHOD OF V_EXCEL 'Range' = V_CRANGE EXPORTING #1 = '5:8'. " Rows 5 - 8 CALL METHOD OF V_CRANGE 'Select'. GET PROPERTY OF V_CRANGE 'font' = V_FONT. SET PROPERTY OF V_FONT 'SIZE' = 11. SET PROPERTY OF V_FONT 'NAME' = 'Arial'.
Add a comment