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

Regarding FM Execution

sreeramkumar_madisetty
Active Contributor
0 Likes
625

Hi Friends

I am using the FM: ARCHIVFILE_SERVER_TO_CLIEN.

With the parameters:

Path = /tmp/TEST EMP COMP COE ECM_MB_07.txt

And target Path = c:\Bonusbudget\TEST EMP COMP COE ECM_MB_07.txt

While executing this FM , if I checked the uppercase/lower case checkbox, I am getting the proper results otherwise I am getting the error that:

Error in opening file /TMP/TEST EMP COMP COE ECM_MB_07.TXT for reading (No such file or directory).

As I am calling this in my program and getting the above error.

Here by dig into the issue,I came to know that if I pass the Parameters as constant values for the above FM ,I am getting the proper results and if I take the parameters as variables, I am getting the errors.

Can anyone please suggest me the solution for this.

Please suggest me any alternate FM or the mechnism to convert Variable to Constant at runtime.

Points are assured for useful answers.

Regards,

Sreeram

1 ACCEPTED SOLUTION
Read only

former_member673464
Active Contributor
0 Likes
584

hi,

I think there is no need for passing the constant values for the function module as most of the programs which are using the function module are using the parameters only.I think you might have declared the variable directly.It is converting the lower case into upper case also.You can use the option of lower case with parameters to get the lower case also in the parameters.Otherwise it will convert it into upper case as you enter the values in the selection-screen.Refer to the function module ARCHIVOBJECT_GET_DT_VIA_SERVER where he is passing the parameters only.

Regards,

Veeresh

3 REPLIES 3
Read only

former_member673464
Active Contributor
0 Likes
585

hi,

I think there is no need for passing the constant values for the function module as most of the programs which are using the function module are using the parameters only.I think you might have declared the variable directly.It is converting the lower case into upper case also.You can use the option of lower case with parameters to get the lower case also in the parameters.Otherwise it will convert it into upper case as you enter the values in the selection-screen.Refer to the function module ARCHIVOBJECT_GET_DT_VIA_SERVER where he is passing the parameters only.

Regards,

Veeresh

Read only

vinod_vemuru2
Active Contributor
0 Likes
584

Hi Sreeram,

Application server file name is case sensitive. So u have to pass the file name with proper case.

Declare one parameter in ur program and add the addition LOWER-CASE.

eg: PARAMETERS: po_file(120) TYPE c LOWER-CASE DEFAULT 'UR default file path name'..

This parameter will act as case sensitive. Now use this parameter. Also it is irrelavent whether it is constant/variable u r using. U cant use TRANSLATE file TO LOWER CASE because file may contain MIX of upper and lower cases.

If ur file path is constant then u can hard code it.

I feel first option will be flexible and makes sense.

Thanks,

Vinod.

Read only

sreeramkumar_madisetty
Active Contributor
0 Likes
584

Closed.