Application Development 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: 

GUI_DOWNLOAD Function module is changing turkish characters to #

Former Member
0 Kudos
608

Hi All ,

I am facing a problem while downloading a file using FM - GUI_DOWNLOAD.

While downloading the data from the internal table to text file the one of the field

vendor name in  which some of the charcters are is in turkish character

ie  ,Name =  ARAS KARGO YURTİÇİ YURTDIŞI TAŞ.AŞ ,the characters I ,C,S are getting changed to #.

Can you please help me.

Please find the code.

 

CALL FUNCTION 'GUI_DOWNLOAD'

EXPORTING

 

* BIN_FILESIZE =

 

filename = filename_string

filetype = 'ASC'

 

* CONFIRM_OVERWRITE = ' '

* NO_AUTH_CHECK = ' '

* CODEPAGE = ' '

* IGNORE_CERR = ABAP_TRUE

* REPLACEMENT = '#'

* WRITE_BOM = ' '

* TRUNC_TRAILING_BLANKS_EOL = 'X'

 

TABLES

data_tab = ta_download

1 ACCEPTED SOLUTION

sandeep_katoch
Contributor
0 Kudos
155

Hi Murali,

Try to pass the relevant codepage in FM.

rgds

sandeep katoch

4 REPLIES 4

sandeep_katoch
Contributor
0 Kudos
156

Hi Murali,

Try to pass the relevant codepage in FM.

rgds

sandeep katoch

0 Kudos
155

Hi Sanddep,

Thanks for the quick reply .

Can you please tell me why TCP0F table is used.

also how to chec whether a language is non-unicode

Thanks & Regards,

Murali Krishnan

0 Kudos
155

Hi Murli,

For table TCP0F pls check this

http://scn.sap.com/thread/1510734

For language languages that are nonunicode check this

http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/f0910e42-2911-2a10-8482-b0fd63ac7...

Rgds,

Sandeep katoch

eyup_aksoy
Explorer
0 Kudos
155

hi

may use this method. İt may work

To avoid this kind of errors use the extension IGNORING CONVERSION ERRORS to the OPEN DATASET statement.

Example:

DATA g_filename TYPE string VALUE 'D:/test.txt'.

OPEN DATASET g_filename FOR INPUT IN TEXT MODE ENCODING DEFAULT IGNORING CONVERSION ERRORS.

READ DATASET g_filename INTO g_chr.
IF sy-subrc EQ 0.
  CLOSE DATASET g_filename.
ENDIF.

or you can use DOWNLOAD, WS_DOWNLOAD functions