mirror of
https://github.com/abap2xlsx/abap2xlsx.git
synced 2025-05-05 13:46:17 +08:00
commit
6781323356
|
@ -51,10 +51,14 @@ public section.
|
||||||
ZCX_EXCEL .
|
ZCX_EXCEL .
|
||||||
methods DELETE_WORKSHEET_BY_INDEX
|
methods DELETE_WORKSHEET_BY_INDEX
|
||||||
importing
|
importing
|
||||||
!IV_INDEX type NUMERIC .
|
!IV_INDEX type NUMERIC
|
||||||
|
raising
|
||||||
|
ZCX_EXCEL .
|
||||||
methods DELETE_WORKSHEET_BY_NAME
|
methods DELETE_WORKSHEET_BY_NAME
|
||||||
importing
|
importing
|
||||||
!IV_TITLE type CLIKE .
|
!IV_TITLE type CLIKE
|
||||||
|
raising
|
||||||
|
ZCX_EXCEL .
|
||||||
methods GET_ACTIVE_SHEET_INDEX
|
methods GET_ACTIVE_SHEET_INDEX
|
||||||
returning
|
returning
|
||||||
value(R_ACTIVE_WORKSHEET) type ZEXCEL_ACTIVE_WORKSHEET .
|
value(R_ACTIVE_WORKSHEET) type ZEXCEL_ACTIVE_WORKSHEET .
|
||||||
|
@ -278,7 +282,12 @@ method CONSTRUCTOR.
|
||||||
me->zif_excel_book_protection~initialize( ).
|
me->zif_excel_book_protection~initialize( ).
|
||||||
me->zif_excel_book_properties~initialize( ).
|
me->zif_excel_book_properties~initialize( ).
|
||||||
|
|
||||||
me->add_new_worksheet( ).
|
try.
|
||||||
|
me->add_new_worksheet( ).
|
||||||
|
catch zcx_excel. " suppress syntax check error
|
||||||
|
assert 1 = 2. " some error processing anyway
|
||||||
|
endtry.
|
||||||
|
|
||||||
me->add_new_style( ). " Standard style
|
me->add_new_style( ). " Standard style
|
||||||
lo_style = me->add_new_style( ). " Standard style with fill gray125
|
lo_style = me->add_new_style( ). " Standard style with fill gray125
|
||||||
lo_style->fill->filltype = zcl_excel_style_fill=>c_fill_pattern_gray125.
|
lo_style->fill->filltype = zcl_excel_style_fill=>c_fill_pattern_gray125.
|
||||||
|
|
|
@ -36,10 +36,14 @@ public section.
|
||||||
value(RS_AREA) type ZEXCEL_S_AUTOFILTER_AREA .
|
value(RS_AREA) type ZEXCEL_S_AUTOFILTER_AREA .
|
||||||
methods GET_FILTER_RANGE
|
methods GET_FILTER_RANGE
|
||||||
returning
|
returning
|
||||||
value(R_RANGE) type ZEXCEL_CELL_VALUE .
|
value(R_RANGE) type ZEXCEL_CELL_VALUE
|
||||||
|
raising
|
||||||
|
ZCX_EXCEL.
|
||||||
methods GET_FILTER_REFERENCE
|
methods GET_FILTER_REFERENCE
|
||||||
returning
|
returning
|
||||||
value(R_REF) type ZEXCEL_RANGE_VALUE .
|
value(R_REF) type ZEXCEL_RANGE_VALUE
|
||||||
|
raising
|
||||||
|
ZCX_EXCEL .
|
||||||
methods GET_VALUES
|
methods GET_VALUES
|
||||||
returning
|
returning
|
||||||
value(RT_FILTER) type ZEXCEL_T_AUTOFILTER_VALUES .
|
value(RT_FILTER) type ZEXCEL_T_AUTOFILTER_VALUES .
|
||||||
|
@ -95,7 +99,9 @@ private section.
|
||||||
data WORKSHEET type ref to ZCL_EXCEL_WORKSHEET .
|
data WORKSHEET type ref to ZCL_EXCEL_WORKSHEET .
|
||||||
data MT_FILTERS type TT_FILTERS .
|
data MT_FILTERS type TT_FILTERS .
|
||||||
|
|
||||||
methods VALIDATE_AREA .
|
methods VALIDATE_AREA
|
||||||
|
raising
|
||||||
|
ZCX_EXCEL .
|
||||||
ENDCLASS.
|
ENDCLASS.
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -98,7 +98,9 @@ public section.
|
||||||
!IP_FROM_ROW type ZEXCEL_CELL_ROW
|
!IP_FROM_ROW type ZEXCEL_CELL_ROW
|
||||||
!IP_FROM_COL type ZEXCEL_CELL_COLUMN_ALPHA
|
!IP_FROM_COL type ZEXCEL_CELL_COLUMN_ALPHA
|
||||||
!IP_ROWOFF type INT4 optional
|
!IP_ROWOFF type INT4 optional
|
||||||
!IP_COLOFF type INT4 optional .
|
!IP_COLOFF type INT4 optional
|
||||||
|
raising
|
||||||
|
ZCX_EXCEL .
|
||||||
methods SET_POSITION2
|
methods SET_POSITION2
|
||||||
importing
|
importing
|
||||||
!IP_FROM type ZEXCEL_DRAWING_LOCATION
|
!IP_FROM type ZEXCEL_DRAWING_LOCATION
|
||||||
|
|
|
@ -24,7 +24,9 @@ public section.
|
||||||
methods SET_COLOR
|
methods SET_COLOR
|
||||||
importing
|
importing
|
||||||
!IP_INDEX type I
|
!IP_INDEX type I
|
||||||
!IP_COLOR type ZEXCEL_STYLE_COLOR_ARGB .
|
!IP_COLOR type ZEXCEL_STYLE_COLOR_ARGB
|
||||||
|
raising
|
||||||
|
ZCX_EXCEL .
|
||||||
protected section.
|
protected section.
|
||||||
*"* protected components of class ZCL_EXCEL_LEGACY_PALETTE
|
*"* protected components of class ZCL_EXCEL_LEGACY_PALETTE
|
||||||
*"* do not include other source files here!!!
|
*"* do not include other source files here!!!
|
||||||
|
|
|
@ -270,7 +270,9 @@ private section.
|
||||||
importing
|
importing
|
||||||
!I_FILENAME type CSEQUENCE
|
!I_FILENAME type CSEQUENCE
|
||||||
returning
|
returning
|
||||||
value(R_EXCEL_DATA) type XSTRING .
|
value(R_EXCEL_DATA) type XSTRING
|
||||||
|
raising
|
||||||
|
ZCX_EXCEL.
|
||||||
methods READ_FROM_LOCAL_FILE
|
methods READ_FROM_LOCAL_FILE
|
||||||
importing
|
importing
|
||||||
!I_FILENAME type CSEQUENCE
|
!I_FILENAME type CSEQUENCE
|
||||||
|
|
|
@ -201,12 +201,20 @@ endmethod.
|
||||||
method LOAD_WORKSHEET.
|
method LOAD_WORKSHEET.
|
||||||
|
|
||||||
data: lo_reader type ref to if_sxml_reader.
|
data: lo_reader type ref to if_sxml_reader.
|
||||||
|
data: lx_not_found type ref to lcx_not_found.
|
||||||
|
|
||||||
lo_reader = get_sxml_reader( ip_path ).
|
lo_reader = get_sxml_reader( ip_path ).
|
||||||
|
|
||||||
read_worksheet_data( io_reader = lo_reader
|
try.
|
||||||
io_worksheet = io_worksheet ).
|
|
||||||
|
|
||||||
|
read_worksheet_data( io_reader = lo_reader
|
||||||
|
io_worksheet = io_worksheet ).
|
||||||
|
|
||||||
|
catch lcx_not_found into lx_not_found.
|
||||||
|
raise exception type zcx_excel
|
||||||
|
exporting
|
||||||
|
error = lx_not_found->error.
|
||||||
|
endtry.
|
||||||
endmethod.
|
endmethod.
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -22,7 +22,9 @@ private section.
|
||||||
methods LOAD_VBAPROJECT
|
methods LOAD_VBAPROJECT
|
||||||
importing
|
importing
|
||||||
!IP_PATH type STRING
|
!IP_PATH type STRING
|
||||||
!IP_EXCEL type ref to ZCL_EXCEL .
|
!IP_EXCEL type ref to ZCL_EXCEL
|
||||||
|
raising
|
||||||
|
ZCX_EXCEL .
|
||||||
ENDCLASS.
|
ENDCLASS.
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -75,13 +75,17 @@ public section.
|
||||||
!IP_START_ROW type ZEXCEL_CELL_ROW
|
!IP_START_ROW type ZEXCEL_CELL_ROW
|
||||||
!IP_START_COLUMN type ZEXCEL_CELL_COLUMN_ALPHA
|
!IP_START_COLUMN type ZEXCEL_CELL_COLUMN_ALPHA
|
||||||
!IP_STOP_ROW type ZEXCEL_CELL_ROW
|
!IP_STOP_ROW type ZEXCEL_CELL_ROW
|
||||||
!IP_STOP_COLUMN type ZEXCEL_CELL_COLUMN_ALPHA .
|
!IP_STOP_COLUMN type ZEXCEL_CELL_COLUMN_ALPHA
|
||||||
|
raising
|
||||||
|
ZCX_EXCEL .
|
||||||
methods ADD_RANGE
|
methods ADD_RANGE
|
||||||
importing
|
importing
|
||||||
!IP_START_ROW type ZEXCEL_CELL_ROW
|
!IP_START_ROW type ZEXCEL_CELL_ROW
|
||||||
!IP_START_COLUMN type ZEXCEL_CELL_COLUMN_ALPHA
|
!IP_START_COLUMN type ZEXCEL_CELL_COLUMN_ALPHA
|
||||||
!IP_STOP_ROW type ZEXCEL_CELL_ROW
|
!IP_STOP_ROW type ZEXCEL_CELL_ROW
|
||||||
!IP_STOP_COLUMN type ZEXCEL_CELL_COLUMN_ALPHA .
|
!IP_STOP_COLUMN type ZEXCEL_CELL_COLUMN_ALPHA
|
||||||
|
raising
|
||||||
|
ZCX_EXCEL .
|
||||||
class-methods FACTORY_COND_STYLE_ICONSET
|
class-methods FACTORY_COND_STYLE_ICONSET
|
||||||
importing
|
importing
|
||||||
!IO_WORKSHEET type ref to ZCL_EXCEL_WORKSHEET
|
!IO_WORKSHEET type ref to ZCL_EXCEL_WORKSHEET
|
||||||
|
|
|
@ -81,7 +81,9 @@ public section.
|
||||||
!IP_COLUMN type CLIKE
|
!IP_COLUMN type CLIKE
|
||||||
!IP_FUNCTION type ZEXCEL_TABLE_TOTALS_FUNCTION
|
!IP_FUNCTION type ZEXCEL_TABLE_TOTALS_FUNCTION
|
||||||
returning
|
returning
|
||||||
value(EP_FORMULA) type STRING .
|
value(EP_FORMULA) type STRING
|
||||||
|
raising
|
||||||
|
ZCX_EXCEL .
|
||||||
methods HAS_TOTALS
|
methods HAS_TOTALS
|
||||||
returning
|
returning
|
||||||
value(EP_RESULT) type ABAP_BOOL .
|
value(EP_RESULT) type ABAP_BOOL .
|
||||||
|
@ -101,7 +103,9 @@ public section.
|
||||||
importing
|
importing
|
||||||
!IP_INCLUDE_TOTALS_ROW type ABAP_BOOL default ABAP_TRUE
|
!IP_INCLUDE_TOTALS_ROW type ABAP_BOOL default ABAP_TRUE
|
||||||
returning
|
returning
|
||||||
value(OV_REFERENCE) type STRING .
|
value(OV_REFERENCE) type STRING
|
||||||
|
raising
|
||||||
|
ZCX_EXCEL .
|
||||||
methods GET_BOTTOM_ROW_INTEGER
|
methods GET_BOTTOM_ROW_INTEGER
|
||||||
returning
|
returning
|
||||||
value(EV_ROW) type I .
|
value(EV_ROW) type I .
|
||||||
|
|
|
@ -224,7 +224,9 @@ class ZCL_EXCEL_WORKSHEET definition
|
||||||
methods DELETE_MERGE
|
methods DELETE_MERGE
|
||||||
importing
|
importing
|
||||||
!IP_CELL_COLUMN type SIMPLE optional
|
!IP_CELL_COLUMN type SIMPLE optional
|
||||||
!IP_CELL_ROW type ZEXCEL_CELL_ROW optional .
|
!IP_CELL_ROW type ZEXCEL_CELL_ROW optional
|
||||||
|
raising
|
||||||
|
ZCX_EXCEL .
|
||||||
methods DELETE_ROW_OUTLINE
|
methods DELETE_ROW_OUTLINE
|
||||||
importing
|
importing
|
||||||
!IV_ROW_FROM type I
|
!IV_ROW_FROM type I
|
||||||
|
|
Loading…
Reference in New Issue
Block a user