Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Problem with column selection in GUI_DOWLOAD

Former Member
0 Likes
420

Hi everyone !

I want to save data from an internal table to a DAT file using GUI_DOWLOAD. In this internal table, there are 2 colums that won't be downloaded so I call the FM this way :

CALL FUNCTION 'GUI_DOWNLOAD'

EXPORTING

FILENAME = L_FILE

FILETYPE = 'DAT'

COL_SELECT = 'X'

COL_SELECT_MASK = V_COLSELECT

TABLES

DATA_TAB = TAB_OUT

FIELDNAMES = TAB_FIELDNAMES.

V_COLSELECT contains an 'X' for each column I need to be downloaded and a space for the 2 other columns.

In the result file, the columns that I didn't select don't appear BUT there are 2 columns with no header and filled with zeros at the right edge of the file. I don't know where these 2 columns come from. Maybe a problem with fieldnames but I'm not sure (in TAB_OUT, all columns are present but in TAB_FIELDNAMES there are only headers for the selected columns).

If anybody have an idea, please just tell me.

Points will be rewarded for helpful answers.

Thanks.

Nicolas.

1 ACCEPTED SOLUTION
Read only

former_member194669
Active Contributor
0 Likes
389

Hi,

Try to keep fields same in TAB_FIELDNAMES and TAB_OUT. because anyway you are using COL_SELECT_MASK.

I think you are using COL_SELECT_MASK properly ie

if you have 6 field in the TAB_OUT out of that you need to donwload 1,3,6 then your

COL_SELECT_MASK will be X X X

aRs

2 REPLIES 2
Read only

former_member194669
Active Contributor
0 Likes
390

Hi,

Try to keep fields same in TAB_FIELDNAMES and TAB_OUT. because anyway you are using COL_SELECT_MASK.

I think you are using COL_SELECT_MASK properly ie

if you have 6 field in the TAB_OUT out of that you need to donwload 1,3,6 then your

COL_SELECT_MASK will be X X X

aRs

Read only

0 Likes
389

Hi a®s !

Thanks for your answer. That solved my problem.

You get full points for that ^^

Regards,

Nicolas.