‎2007 Jan 25 4:30 AM
Hi,
I am using the function module EPS_GET_DIRECTORY_LISTING in my batch program to get the file names from the given directory. It works fine, when it is executed online. But if it is executed in background mode, it sometimes returns sy-subrc = 17 (READ DIRECTORY FAILED) and sometimes it is successful.
There is no pattern in returning this kind of result. It seems to be completely random.
I thought of using another function module RZL_READ_DIR_LOCAL. But it behaves the same way.
Could any of you help me to get a solution?
Thanks,
Vasanth
‎2007 Jan 25 5:30 AM
Hi Vasanth
As FM: EPS_GET_DIRECTORY_LISTING is RFC enabled, there shouldnt be any problem with the FM.
Please check on the following:
1. Does your path of your directory change all the time???
2. One reason can be Network load...
I somehow strongly beleive this is due to a wrong directory name.
Maybe you can try by giving the output(display) of the path when there is a failure.
This might give some clue.
Kind Regards
Eswar
‎2007 Jan 25 5:30 AM
Hi Vasanth
As FM: EPS_GET_DIRECTORY_LISTING is RFC enabled, there shouldnt be any problem with the FM.
Please check on the following:
1. Does your path of your directory change all the time???
2. One reason can be Network load...
I somehow strongly beleive this is due to a wrong directory name.
Maybe you can try by giving the output(display) of the path when there is a failure.
This might give some clue.
Kind Regards
Eswar
‎2007 Jan 25 5:49 AM
Hi,
I think it is the problem with the directory name that you are providing. the directory names must and should always be in small letters. try providing the same with small letters only.
regards,
Mahesh
‎2007 Jan 25 6:00 PM
Hi Eswar,
I tried giving the way you suggested. The path doesn't change at all. I keep executing from SM36 with the same variant. So there is no room for giving wrong file path. One time it works and the next time it doesn't. But evertime the file path is displayed properly.
Please advise.
Thanks,
Vasanth
‎2007 Aug 01 2:51 PM
Hi Vasanth,
I am Brasilian and not speak english very well.
I am using this FM to get list of files in directory and no have problems. For execution in background, I am informing the DNS dir.
Exemplo. "
SERVER\DIR\" and no "C:\".
[],
Marcus Farias
‎2008 Jun 09 7:32 PM
Hi Guys,
I need help, I trying to use this C_DIR_READ_NEXT in background but the list of directory return empty, but in foreground return with itens. This function execute in background or only in foreground ?
Thanks,
Marcelo Costa