Path: csiph.com!x330-a1.tempe.blueboxinc.net!aioe.org!news.glorb.com!news-in-01.newsfeed.easynews.com!easynews!core-easynews-01!easynews.com!en-nntp-02.am2.easynews.com.POSTED!not-for-mail From: scbs29 Newsgroups: comp.lang.basic.visual.misc Subject: Re: shell function and pdf in vb6 Message-ID: References: X-Newsreader: Forte Agent 2.0/32.652 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Lines: 28 X-Complaints-To: abuse@easynews.com Organization: Forte Inc. http://www.forteinc.com/apn/ X-Complaints-Info: Please be sure to forward a copy of ALL headers otherwise we will be unable to process your complaint properly. Date: Mon, 09 May 2011 20:06:46 +0100 Xref: x330-a1.tempe.blueboxinc.net comp.lang.basic.visual.misc:144 On Mon, 09 May 2011 19:06:23 +0100, Dee Earley wrote: >On 09/05/2011 18:02, scbs29 wrote: >> Hello all >> As part of a program which I am writing for my wife's craft pictures I >> have just found a need to display pdf files. >> I can do this ok (with foxit reader) using code of the form >> strInstructions = """c:\program files\foxit software\foxit >> reader\foxit reader.exe""" >> strInstructions = strInstructions& " "& """"& filename& """" >> >> so that for a file c:\a_folder\another_folder\filename >> the full call would be >> retval = shell("c:\program files\foxit software\foxit reader\foxit >> reader.exe" "c:\a_folder\another_folder\filename") >> >> Surely there is a more elegant way of doing this ? >> Can anyone advise ? > >Use ShellExecute() >http://hashvb.earlsoft.co.uk/ShellExecute Thanks for the reply. That works fine. remove fred before emailing Registered Linux User 490858