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

File uploading error

Former Member
0 Likes
804

Hi Friends,

i am getting an error, when i am uploading a file. This is because of File Path is more that 1024 char's.

I am using Method FILE_OPEN_DIALOG.

File name size is 1024.

FILENAME CHAR 1024 0 File name

Can you please tell me the ulternate solution for uploading a large file path ( more that 1024 char) files.

Thanks in advance.

Rgards,

Kumar.

5 REPLIES 5
Read only

Former Member
0 Likes
741

Hi Nivas,

try FM 'TMP_GUI_FILE_OPEN_DIALOG' This Function Module alows us to Select a file in Runtime.

Ex



DATA: RETURN TYPE I.

call Function 'TMP_GUI_FILE_OPEN_DIALOG'.

EXPORTING
   WINDOW_TITLE = 'FLAT FILE SELECTION'
IMPORTING
    RC                 =    RETURN
    FILE_TABLE  = IT_FNAM.   
 

Regards,

Murthy.

Read only

Former Member
0 Likes
741

Hi Kumar,

no idea in SAP,

but in Windows OS you can connect a directory as a net drive in Windows Explorer.

If you are using Windows, you can connect a path


SERVER\Directory_1\...\Directory_n

to a free single drive char, e.g. "W".

So you can access files with W:. instead of the long term. Maybe it help you!

Regards,

Klaus

Read only

Former Member
0 Likes
741

best method for this would be: copy it to your desktop or a particular drive. then upload it from there.. easy solution

Read only

Former Member
0 Likes
741

store the file on apps server or server that can be reached from SAP and where SAP has open/read permissions, and use OPEN DATASET, READ..., CLOSE.... see ABAP help for these keywords if you're not familiar with reading from a server... you can handle very, very long record lengths with this methodology.

Read only

0 Likes
741

Hi

Try calling function module 'F4_FILENAME' under ABAP event AT SELECTION-SCREEN OUTPUT ON VALUE REQUEST FOR <p_name>.

Try doing where used list on the function module and you should get many examples in the system.

Regards,

Rupesh