I'm opening some text reports using notepad (the default for these files) which works fine, but I would like to open them as read only. I assume it has something to do with the Parameters but I can't find any information on them.
Auguy
Sylvania/Toledo Ohio
Code:
LOCAL cFullFileName
cFullFileName = "Old Reports\" + ALLTRIM(This.Value) + ".LST"
If Not Thisform.ShellExecute
DECLARE INTEGER ShellExecute ;
IN SHELL32.DLL ;
INTEGER nWinHandle,;
STRING cOperation,;
STRING cFullFileName,;
STRING cParameters,;
STRING cDirectory,;
INTEGER nShowWindow
Thisform.ShellExecute = .T.
Endif
* Open File Using Default File Association
If File(cFullFileName)
Try
ShellExecute(0, "open", cFullFileName, "", "", 1)
ENDTRY
Else
Do Form MessageForm with 'Notice', ;
'File doest not exist.', ;
(gButtonOK), (gIconExclaim), (gDefaultButton1st)
ENDIF
Auguy
Sylvania/Toledo Ohio