2006 Sep 26 3:29 AM
Hello All,
I have a program which automatically downloads the output to a .csv file. I have already successfully downloaded the output to a .csv file, however, some of my fields, like Shipping Instructions Text from the Header of a Sales Order is not left-justified when i check the file. I want all the fields to be left-justified so i don't have to check the fields one by one to see if it has a value or not. I have already tried the CONDENSE syntax and SHIFT LEFT syntax, but my downloaded file is still not left justified.
Any suggestions to make all the fields of the csv file left justified?
Thanks!
Jim
2006 Sep 26 3:56 AM
Hi Jim,
Please specify the file type in GUI_DOWNLOAD FM.
CALL FUNCTION 'GUI_DOWNLOAD' "#EC *
EXPORTING
filename = v_detail_name
<b>Filetype = 'ASC'</b>
TABLES
data_tab = i_scsvtab_header
EXCEPTIONS
OTHERS = 1.
Best regards,
Prashant
PS : Please reward all helpful answers
Hello All,
I have a program which automatically downloads the output to a .csv file. I have already successfully downloaded the output to a .csv file, however, some of my fields, like Shipping Instructions Text from the Header of a Sales Order is not left-justified when i check the file. I want all the fields to be left-justified so i don't have to check the fields one by one to see if it has a value or not. I have already tried the CONDENSE syntax and SHIFT LEFT syntax, but my downloaded file is still not left justified.
Any suggestions to make all the fields of the csv file left justified?
Thanks!
Jim
2006 Sep 26 3:33 AM
Hi Jim,
Could you please paste the code. Need to check the data type of the internal table which is passed to GUI_DOWNLOAD.
Best regards,
Prashant
2006 Sep 26 3:42 AM
CALL FUNCTION 'GUI_DOWNLOAD' "#EC *
EXPORTING
filename = v_detail_name
TABLES
data_tab = i_scsvtab_header
EXCEPTIONS
OTHERS = 1.
IF sy-subrc = 0.
CALL FUNCTION 'GUI_DOWNLOAD' "#EC *
EXPORTING
filename = v_detail_name
append = c_a
TABLES
data_tab = i_scsvtab
EXCEPTIONS
OTHERS = 1.
IF sy-subrc <> 0.
ENDIF.
ELSE.
do nothing
ENDIF.
Here's the declaration of the internal table:
DATA: BEGIN OF i_scsvtab OCCURS 0,
auart(4), "order type
vkorg(5), "sales org
vtweg(3), "distribution channel
spart(3), "division
kunnr(11), "sold to
kunwe(11), "ship to
bstkd(21), "customer PO
bstdk(11), "customer PO date
vdatu(11), "RDD
augru(41), "reason code
tbnth(41), "Billing Notes
tsins(41), "Shipping Instructions
matnr(19), "material
kwmeng(16), "quantity
vrkme(4), "UoM
werks(5), "plant
charg(11), "batch
netpr(12), "net price
kpein(6), "pricing unit
tbnti(41), "Billing Notes
zmess(46),
zflag(2),
END OF i_scsvtab.
Do i need to change the declaration??
Thanks!
2006 Sep 26 3:56 AM
Hi Jim,
Please specify the file type in GUI_DOWNLOAD FM.
CALL FUNCTION 'GUI_DOWNLOAD' "#EC *
EXPORTING
filename = v_detail_name
<b>Filetype = 'ASC'</b>
TABLES
data_tab = i_scsvtab_header
EXCEPTIONS
OTHERS = 1.
Best regards,
Prashant
PS : Please reward all helpful answers
| User | Count |
|---|---|
| 4 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |