- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
In reference to post:
Getting error code 29 on open with executable
Using IFQWIN, this statement works as expected - opens a windows explorer and allows user to (1)select a file: Open(11,FILE=' ',READONLY,STATUS='OLD',ERR=1004,IOSTAT=Iodum)
If I want to allow the user to input a path for the directory (variable wfolder), I did the following (2)statement: Open(11,FILE=wfolder//' ',READONLY,STATUS='OLD',ERR=1004,IOSTAT=Iodum)
However, when building the solution in Visual Studio 2019, it gives me the following error:
error #5082:Syntax error, found END-OF-STATEMENT when expecting one of :),
This setting in VS Studio 2019 works where I get no error 29 [with (1) above] when compiling from solution in above stated post:
(
Thanks for the assistance.
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You can’t do it this way, though I’m guessing the actual code you have isn’t the same as what you posted given the syntax error. See if the OPEN keyword DEFAULTFILE does what you want. The prompt feature works only when the FILE= value is completely blank.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks, the original code is number (1) in my original post. It opens a window explorer in the current working directory and allows the user to select any file. I want to change this to allow the user to input a directory path and select any file in that path.
I tried the following:
character wfolder
wfolder = ' '
Open(11,DEFAULTFILE=wfolder,READONLY,STATUS='OLD',ERR=1004,IOSTAT=Iodum)
This gives me syntax error #5082 and error #6318
also tried:
character wfolder
wfolder = ' '
Open(11,FILE=' ',DEFAULTFILE=wfolder,READONLY,STATUS='OLD',ERR=1004,IOSTAT=Iodum)
This gives me syntax error #5082 and error #6323
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
character wfolder
wfolder = ' '
Open(11,DEFAULTFILE=wfolder,READONLY,STATUS='OLD',ERR=1004,IOSTAT=Iodum)
character wfolder
wfolder = ' '
Open(11,FILE=' ',DEFAULTFILE=wfolder,READONLY,STATUS='OLD',ERR=1004,IOSTAT=Iodum)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
This solution does not work for lines (7 - 11). Thank you.
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page