On Mon, 2012-03-05 at 12:16 +0800, Ian Roper wrote: > Could you use > Exec ["xdg-open", Application.path &/ "myfile.pdf"] > > or is the bad practice ? > > Note # xdg-open is on most Linux Distros and will open a nominated file > with the correct program if there is one installed for this purpose. > > Regards, > Ian Roper ~ Perth - Western Australia. > N.B. gb.desktop provides the static Desktop class that does that exact thing i.e. it runs the xdg.open script (the "portland" script) that is included in gambas. Also note that in my experience, few distros have kept up to date with the portland project scripts. The ones included inside gambas are more up to date than several distros.
So: Dim tmpfile as String tmpfile=Temp$("myPDF.pdf") Copy "myPDF.pdf" to tmpfile Desktop.Open(tmpfile) or similar should do the trick Bruce ------------------------------------------------------------------------------ Try before you buy = See our experts in action! The most comprehensive online learning library for Microsoft developers is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, Metro Style Apps, more. Free future releases when you subscribe now! http://p.sf.net/sfu/learndevnow-dev2 _______________________________________________ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user