cancel
Showing results for 
Search instead for 
Did you mean: 

ABAP to change uploaded UJFS Excel template and change member selection for Distribution template

mark_dean
Explorer
0 Kudos
574

Hi guys,

Starting to a little crazy with this. Using ABAP need to upload a BPC Excel Distribution template, and then change master data dimension members in it, and save it back to UJFS.

I have tried debugging the downloading of an Excel distribution template from the Excel front end, and I think it uses SAP Transformations (Call Transformation), but I don't understand those.

Is there a way to upload the file to xstring, and then convert the part where the BPC Dimension members need to be updated, and then save the file back to UJFS ?

I have tried FM's SCMS_XSTRING_TO_BINARY, THEN SCMS_BINARY_TO_STRING etc. but I never get anything readable. SAP Class CL_ABAP_CONV_IN_CE etc.

I have tried class cl_fdt_xl_spreadsheet, and I get the itab containing the worksheet contents, and then I tried to have named cells, which I can read using Method IF_FDT_DOC_SPREADSHEET~GET_NAMED_CELL_VALUE, but I cannot seem to write a new value using method IF_FDT_DOC_SPREADSHEET~SET_NAMED_CELL_VALUE.

Any pointers please ?

Thanks

Mark

View Entire Topic
mark_dean
Explorer
0 Kudos

The answer to my issue was to use ABAP2XLSX software downloaded from SAP Github.

This provides all the classes and methods to download excel spreadsheets, manipulate them using ABAP and save back in .xlsx format.