With Thisform .oExcel = CREATEOBJECT( "excel.application") .oExcel.Workbooks.Open( lcFileToOpen) .oExcel.Visible = .T. .oExcel.Range("A1").Select Endwithor: (think this works):
ShellExecute( 0, "Open", "myPDFDoc.PDF", ["] + lcFileToOpen + ["], "", 1)or:
DECLARE INTEGER ShellExecute IN "Shell32.dll" ; INTEGER hwnd, ; STRING lpVerb, ; STRING lpFile, ; STRING lpParameters, ; STRING lpDirectory, ; LONG nShowCmd lcPDFfile = "c:\mydir\myfile.pdf" * Open PDF file =Shellexecute(0,"Open", lcPDFfile, "","",7) * Print PDF file =Shellexecute(0,"Print", lcPDFfile, "","",0)or:
oShell = CreateObject( "WScript.Shell") oShell.Run( ( lcFullPathAndExtension), 1, .T.)HTH