In my system, there are many instances of Opening a file where I do the following
Do trmatt2 With Sys(5)+Curdir()+"PAYREP3.XLSX",'OPEN' and trmatt2 looks like this
LPARAMETERS tcFile, tcAction
tcFile =IIF(type("tcFile")="C",tcFile,sys(5)+curdir()+"README.RTF") tcAction='OPEN'
if !file(tcFile) =messagebox('Sorry, problem finding the file ',0,'') else wait window nowait 'Opening '+tcFile
DECLARE INTEGER ShellExecute ; IN SHELL32.dll ; INTEGER nWinHandle,; STRING cOperation,; STRING cFileName,; STRING cParameters,; STRING cDirectory,; INTEGER nShowWindow
DECLARE INTEGER FindWindow IN WIN32API STRING cNull,STRING cWinName
RETURN ShellExecute(FindWindow(0,_SCREEN.caption),tcAction,tcFile,"",SYS(2023),1) endif
This is working fine with all manner of files, EXCEPT JPG files Can anyone help me with this?