F
Frederik Romanov
Excel-97 (SR-2)
My Excel version 4 manual describes the obsolete form of Fopen, with
this syntax I hoped to perform
[G15:FileNonExistent] = <within a macro> isNA( Fopen(
"C:\datafile.pdf", 2))
However the syntax in Excel-97 now means I have to use
[G15:FileNonExistent] = <within a macro> open "C:\datafile.pdf" for
input as #123
Trouble is this does not return a status, but generates an error if
the file does not exist. How can the macro trap this error and convert
it to a return status?
When I actually tried this with a non-existent file, the cell invoking
the macro just displays #Value!, only if I step into the macro do I
get an error reported.
TIA (thanks in advance),
Fred.
My Excel version 4 manual describes the obsolete form of Fopen, with
this syntax I hoped to perform
[G15:FileNonExistent] = <within a macro> isNA( Fopen(
"C:\datafile.pdf", 2))
However the syntax in Excel-97 now means I have to use
[G15:FileNonExistent] = <within a macro> open "C:\datafile.pdf" for
input as #123
Trouble is this does not return a status, but generates an error if
the file does not exist. How can the macro trap this error and convert
it to a return status?
When I actually tried this with a non-existent file, the cell invoking
the macro just displays #Value!, only if I step into the macro do I
get an error reported.
TIA (thanks in advance),
Fred.