Quantcast
Channel: NAV Three Tier — mibuso.com
Viewing all articles
Browse latest Browse all 10032

How to find out names of all files saved in a folder and error "The maximum length for a string ..."

$
0
0
Hi all,
is there some workaround? I use this C/AL:
RecLFile.SETRANGE(Path, MySearchigFolder);
RecLFile.SETRANGE(RecLFile."Is a file", TRUE);
IF RecLFile.FIND('-') THEN BEGIN
  //somethig what you want
UNTIL RecLFile.NEXT = 0;
This C/AL will works with no error if MySearchigFolder is not nested too deep. If MySearchigFolder is for instance "C:\ProgramData\Microsoft\Microsoft Dynamics NAV\60\Server\MicrosoftDynamicsNavServer\users\DOM\John.Parker\TEMP" (default value of TEMPORARYPATH) the error (The maximum length for a string value is 98.) will displayed because field Path in table File is declared as text 98.

Any idea how to get name of all files and not to use .NET (Automation)?

Viewing all articles
Browse latest Browse all 10032

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>