Quantcast
Channel: Chilkat Forum - latest questions
Viewing all articles
Browse latest Browse all 1061

GetFilename not always working (FPT2 connection to mainframe)

$
0
0

After setting the ListPattern to the latest GDG reference, 'filename(0)', I was able to return the file name getting the FULL file name a 'filename.G0001V00'. That was yesterday.

Today is a different story. I get "Nothing" returned from the GetFilename(0) call.

I really want to know the actual generation number, but now I can't find a stable, consistent way to do this!

Has anyone experience sporadic success with GetFilename?

To clarify ----- The problem is very intermittent. For several days in a row, a mainframe GDG exists with the latest generation at "G0004V00". I have a job scheduled to run several times each day to pull the latest GDG (generation zero).

The defined number of generations for this file is 3, so these files are on the mainframe: 'my.mainframe.file.G0002V00' 'my.mainframe.file.G0003V00' 'my.mainframe.file.G0004V00'

Here's the code snippet: RemoteFileName = "'my.mainframe.file(0)'" loFTP.ListPattern = RemoteFileName ActualRemoteFileName = loFTP.GetFilename(0)

What happens in GetFilename(0)? Sometimes (often the first execution of the day but not always), the variable "ActualRemoteFileName" contains "Nothing" (it is empty!), however in most of the executions on the same day this same variable will contain "'my.mainframe.file.G0004V00'".

Purely intermittent! The code has not changed for many days.

Plus, I've not seen "only the file node" returned. It's always been empty or the actual full GDG name.


Viewing all articles
Browse latest Browse all 1061

Trending Articles