abap2xlsx
abap2xlsx copied to clipboard
how to delete a row in worksheet ?
I want to delete a row in worksheet,but I can not find a method which can delete a row. Who can help me? Think you very much
class ZCL_EXCEL_ROWS, method REMOVE ?
class ZCL_EXCEL_ROWS, method REMOVE ?
this is my code. It can remove a row from rows. `
DATA:
lo_worksheet TYPE REF TO zcl_excel_worksheet,
lo_row TYPE REF TO zcl_excel_row.
lo_row = lo_worksheet->get_row( ip_row = 11 ).
lo_rows = lo_worksheet->get_rows( ).
lo_rows->remove( io_row = lo_row ).
`
I want code can do that:
lo_worksheet->delete_row( ip_row = 11 ).
I think the object model must remain as it is (and to be the same as the Microsoft Excel programming model), but maybe we could improve to make this possible?
lo_worksheet->get_rows( )->remove( ip_index = 11 ).
Could you contribute to do this enhancement by forking the project and do a pull request?
To participate and propose a fix to improve abap2xlsx:
- at https://github.com
- Create your github account/space if not done yet (for instance janeorjohndoe)
- Navigate to https://github.com/abap2xlsx/abap2xlsx
- Click the "Fork" button at the top of the page; this will duplicate the repository to your github space
- Run ZABAPGIT at your ABAP server
- If the abap2xlsx repository is not pulled yet, click "New online", https://github.com/janeorjohndoe/abap2xlsx, enter an ABAP package name/prefix whose abap2xlsx objects will be assigned to, click "Create online", then click "Pull", and confirm till all abap2xlsx objects are activated in your ABAP server
- Create a branch by clicking
master
, typing any name you want which describes your fix, then clicking "Create branch"
- Do your abap2xlsx modifications
- Run ZABAPGIT at your ABAP server
- Select the line corresponding to abap2xlsx (click anywhere in the line but hyperlinks)
- Click "Stage", confirm the objects to stage, do a Diff to verify your changes for the last time, choose your pseudonym and email address, and click "Commit".