1. Displaying HTML
- Posted by Philip Deets <philip1987 at hotmail.com> Feb 03, 2004
- 528 views
Hi, I want to add a View ReadMe Menu Item to the Help Menu in my program. The readme is in HTML. I've looked through the platform SDK but can't find any answers. Can you help me? Windows XP SP1 win32lib 0.59.1 (the latest, I think) Thanks, Phil
2. Re: Displaying HTML
- Posted by Pete Lomax <petelomax at blueyonder.co.uk> Feb 03, 2004
- 494 views
On Tue, 3 Feb 2004 01:22:02 +0000, Philip Deets <philip1987 at hotmail.com> wrote: >Hi, I want to add a View ReadMe Menu Item to the Help Menu in my >program. The readme is in HTML. I've looked through the platform SDK >but can't find any answers. Can you help me? > >Windows XP SP1 >win32lib 0.59.1 (the latest, I think) > >Thanks, >Phil Here is an example from MEditor: procedure onClickEuManual(integer self, integer event, sequence params) object void sequence helpfilepath -- open the HTML version of refman.doc helpfilepath=getenv("EUDIR")&"\\HTML\\Refman.htm" void = open(helpfilepath, "r") if void != -1 then -- see if Euphoria manual present close(void) shellExecute("open",helpfilepath, SW_SHOWMAXIMIZED) else void = message_box("Euphoria Manual not present in Euphoria directory"&10&13& helpfilepath, "Euphoria Manual not found", 0 ) end if end procedure setHandler(HelpEuph,w32HClick,routine_id("onClickEuManual")) HTH, Pete
3. Re: Displaying HTML
- Posted by "Hayden McKay" <hmck1 at dodo.com.au> Feb 03, 2004
- 488 views
One way is to use 'system_exec()' with the filename. and let the users defualt browser open the the file. ex: integer code code = system_exec("ReadMe.html",2) Under WINDOWS the above should open a browser window with the readme in it. ----- Original Message ----- From: "Philip Deets" <philip1987 at hotmail.com> To: <EUforum at topica.com> Sent: Tuesday, February 03, 2004 12:22 PM Subject: Displaying HTML > > > Hi, I want to add a View ReadMe Menu Item to the Help Menu in my > program. The readme is in HTML. I've looked through the platform SDK > but can't find any answers. Can you help me? > > Windows XP SP1 > win32lib 0.59.1 (the latest, I think) > > Thanks, > Phil > > > > TOPICA - Start your own email discussion group. FREE! > > > -- > Incoming mail is certified Virus Free. > Checked by AVG anti-virus system (http://www.grisoft.com). > Version: 6.0.572 / Virus Database: 362 - Release Date: 27/01/04 > --- --
4. Re: Displaying HTML
- Posted by "Juergen Luethje" <j.lue at gmx.de> Feb 04, 2004
- 557 views
Hayden McKay wrote: > One way is to use 'system_exec()' with the filename. > and let the users defualt browser open the the file. > > ex: > integer code > code = system_exec("ReadMe.html",2) > > Under WINDOWS the above should open a browser window with the readme in it. What Windows version and what Euphoria version are you using? On my system -- Windows 98, Euphoria 2.4 (tested by using "exw.exe") -- this does not work. I actually can't imagine, that the suggested method would work as expected on any other Windows version. However, "good old" ShellExecute does the job. Regards, Juergen > ----- Original Message ----- > From: "Philip Deets" > Sent: Tuesday, February 03, 2004 12:22 PM > > >> Hi, I want to add a View ReadMe Menu Item to the Help Menu in my >> program. The readme is in HTML. I've looked through the platform SDK >> but can't find any answers. Can you help me? >> >> Windows XP SP1 >> win32lib 0.59.1 (the latest, I think) >> >> Thanks, >> Phil
5. Re: Displaying HTML
- Posted by isaac-topica at blueapples.org Feb 05, 2004
- 488 views
Actually, this should work just fine. The result will be that the HTML file is displayed in the default browser, just as if it where double clicked in your favorite file manager. This is exactly how those programs open files when you ask them to. ~ Isaac Quoting Juergen Luethje <j.lue at gmx.de>: > > > Hayden McKay wrote: > > > One way is to use 'system_exec()' with the filename. > > and let the users defualt browser open the the file. > > > > ex: > > integer code > > code = system_exec("ReadMe.html",2) > > > > Under WINDOWS the above should open a browser window with the readme in > it. > > What Windows version and what Euphoria version are you using? > On my system -- Windows 98, Euphoria 2.4 (tested by using "exw.exe") -- > this does not work. I actually can't imagine, that the suggested method > would work as expected on any other Windows version. > > However, "good old" ShellExecute does the job. > > Regards, > Juergen > > > > ----- Original Message ----- > > From: "Philip Deets" > > Sent: Tuesday, February 03, 2004 12:22 PM > > > > > >> Hi, I want to add a View ReadMe Menu Item to the Help Menu in my > >> program. The readme is in HTML. I've looked through the platform SDK > >> but can't find any answers. Can you help me? > >> > >> Windows XP SP1 > >> win32lib 0.59.1 (the latest, I think) > >> > >> Thanks, > >> Phil > > > > TOPICA - Start your own email discussion group. FREE! > >
6. Re: Displaying HTML
- Posted by "Juergen Luethje" <j.lue at gmx.de> Feb 05, 2004
- 498 views
isaac-topica wrote: > Actually, this should work just fine. What do you mean by "should"? I tested it, and it did *not* work on my system. Did you actually test it? If you did so, on what system? Which Windows version, and which Euphoria version? What *exactly* did you do? Facts please ... > The result will be that the HTML file is > displayed in the default browser, As I previously wrote, that was *not* the result, that I got. When I called integer code code = system_exec("ReadMe.html", 2) actually nothing happend on my system. The file "ReadMe.html" was in the same directory as the regarding Euphoria program. > just as if it where double clicked in your > favorite file manager. This is exactly how those programs open files when you > ask them to. > > ~ Isaac Regards, Juergen > Quoting Juergen Luethje: > >> Hayden McKay wrote: >> >>> One way is to use 'system_exec()' with the filename. >>> and let the users defualt browser open the the file. >>> >>> ex: >>> integer code >>> code = system_exec("ReadMe.html",2) >>> >>> Under WINDOWS the above should open a browser window with the readme in >>> it. >> >> What Windows version and what Euphoria version are you using? >> On my system -- Windows 98, Euphoria 2.4 (tested by using "exw.exe") -- >> this does not work. I actually can't imagine, that the suggested method >> would work as expected on any other Windows version. >> >> However, "good old" ShellExecute does the job. >> >> Regards, >> Juergen >> >> >>> ----- Original Message ----- >>> From: "Philip Deets" >>> Sent: Tuesday, February 03, 2004 12:22 PM >>> >>> >>>> Hi, I want to add a View ReadMe Menu Item to the Help Menu in my >>>> program. The readme is in HTML. I've looked through the platform SDK >>>> but can't find any answers. Can you help me? >>>> >>>> Windows XP SP1 >>>> win32lib 0.59.1 (the latest, I think) >>>> >>>> Thanks, >>>> Phil
7. Re: Displaying HTML
- Posted by "Juergen Luethje" <j.lue at gmx.de> Feb 06, 2004
- 490 views
Matt wrote: > Juergen Luethje wrote: >> >> isaac-topica wrote: >> >>> Actually, this should work just fine. >> >> What do you mean by "should"? >> I tested it, and it did *not* work on my system. >> Did you actually test it? If you did so, on what system? >> Which Windows version, and which Euphoria version? >> What *exactly* did you do? Facts please ... >> >>> The result will be that the HTML file is >>> displayed in the default browser, >> >> As I previously wrote, that was *not* the result, that I got. >> When I called >> integer code >> code = system_exec("ReadMe.html", 2) >> actually nothing happend on my system. The file "ReadMe.html" was >> in the same directory as the regarding Euphoria program. > > On Win2K, system_exec() does nothing, but system() opens the file in IE > (my default browser). Thanks for the information, Matt. On my computer (Win 98), system() also does *nothing*. Strange. Regards, Juergen
8. Re: Displaying HTML
- Posted by Isaac Raway <isaac-topica at blueapples.org> Feb 06, 2004
- 497 views
Juergen Luethje wrote: > > >isaac-topica wrote: > > >>Actually, this should work just fine. >> >> >What do you mean by "should"? >I tested it, and it did *not* work on my system. >Did you actually test it? If you did so, on what system? >Which Windows version, and which Euphoria version? >What *exactly* did you do? Facts please ... > > I have called this API from C++ and Visual Basic. It works. If it didn't work for you, then there is most likely something misconfigured in your registry. >>The result will be that the HTML file is >>displayed in the default browser, >> >> >As I previously wrote, that was *not* the result, that I got. >When I called > integer code > code = system_exec("ReadMe.html", 2) >actually nothing happend on my system. The file "ReadMe.html" was in the >same directory as the regarding Euphoria program. > > >>just as if it where double clicked in your >>favorite file manager. This is exactly how those programs open files when you >>ask them to. >> >>~ Isaac >> >> >Regards, > Juergen > > >>Quoting Juergen Luethje: >> >> >>>Hayden McKay wrote: >>> >>> >>>>One way is to use 'system_exec()' with the filename. >>>>and let the users defualt browser open the the file. >>>> >>>>ex: >>>> integer code >>>> code = system_exec("ReadMe.html",2) >>>> >>>>Under WINDOWS the above should open a browser window with the readme in >>>>it. >>>> >>>> >>>What Windows version and what Euphoria version are you using? >>>On my system -- Windows 98, Euphoria 2.4 (tested by using "exw.exe") -- >>>this does not work. I actually can't imagine, that the suggested method >>>would work as expected on any other Windows version. >>> >>>However, "good old" ShellExecute does the job. >>> >>>Regards, >>> Juergen >>> >>> >>>>----- Original Message ----- >>>>From: "Philip Deets" >>>>Sent: Tuesday, February 03, 2004 12:22 PM >>>> >>>> >>>> >>>> >>>>>Hi, I want to add a View ReadMe Menu Item to the Help Menu in my >>>>>program. The readme is in HTML. I've looked through the platform SDK >>>>>but can't find any answers. Can you help me? >>>>> >>>>>Windows XP SP1 >>>>>win32lib 0.59.1 (the latest, I think) >>>>> >>>>>Thanks, >>>>>Phil >>>>> >>>>> > > > >TOPICA - Start your own email discussion group. FREE! > >
9. Re: Displaying HTML
- Posted by "Derek Parnell" <ddparnell at bigpond.com> Feb 06, 2004
- 501 views
----- Original Message ----- From: "Isaac Raway" <isaac-topica at blueapples.org> To: <EUforum at topica.com> Subject: Re: Displaying HTML > > > Juergen Luethje wrote: > > > > >isaac-topica wrote: > > > > > >>Actually, this should work just fine. > >> > >> > >What do you mean by "should"? > >I tested it, and it did *not* work on my system. > >Did you actually test it? If you did so, on what system? > >Which Windows version, and which Euphoria version? > >What *exactly* did you do? Facts please ... > > > > > I have called this API from C++ and Visual Basic. It works. If it didn't > work for you, then there is most likely something misconfigured in your > registry. What *API* are you talking about? The EUPHORIA routine called "system_exec" has nothing to do with any Windows API. It is equivalent to opening a DOS window and typing in the parameter at the DOS prompt. Thus 'system_exec("ReadMe.html", 2)' is like typing "ReadMe.html" at a DOS prompt. IT does NOT open a browser to display the html file. If you read the Euphoria documentation for this routine it says that the parameter "must be a command to run an executable program" - and a HTML file is not one of those. The fact that C++ and VB have a 'system_exec' type of routine does NOT mean that they are the same as Euphoria's routine. The Windows API routine called 'shellexecute' is most likely what the VB and C++ routines use. -- Derek
10. Re: Displaying HTML
- Posted by Isaac Raway <isaac-topica at blueapples.org> Feb 06, 2004
- 478 views
I apologize. I just assumed that system_execute was calling ShellExecute. Use ShellExecute, problem solved. Derek Parnell wrote: > > >----- Original Message ----- >From: "Isaac Raway" <isaac-topica at blueapples.org> >To: <EUforum at topica.com> >Sent: Saturday, February 07, 2004 10:01 AM >Subject: Re: Displaying HTML > > >>Juergen Luethje wrote: >> >> >>>isaac-topica wrote: >>> >>> >>>>Actually, this should work just fine. >>>> >>>> >>>> >>>> >>>What do you mean by "should"? >>>I tested it, and it did *not* work on my system. >>>Did you actually test it? If you did so, on what system? >>>Which Windows version, and which Euphoria version? >>>What *exactly* did you do? Facts please ... >>> >>> >>I have called this API from C++ and Visual Basic. It works. If it didn't >>work for you, then there is most likely something misconfigured in your >>registry. >> >> >What *API* are you talking about? The EUPHORIA routine called "system_exec" has >nothing to do with any Windows API. It is equivalent to opening a DOS window and >typing in the parameter at the DOS prompt. Thus 'system_exec("ReadMe.html", 2)' >is like typing "ReadMe.html" at a DOS prompt. IT does NOT open a browser to >display the html file. If you read the Euphoria documentation for this routine it >says that the parameter "must be a command to run an executable program" - and a >HTML file is not one of those. > >The fact that C++ and VB have a 'system_exec' type of routine does NOT mean >that they are the same as Euphoria's routine. > >The Windows API routine called 'shellexecute' is most likely what the VB and >C++ routines use. > >
11. Re: Displaying HTML
- Posted by "Derek Parnell" <ddparnell at bigpond.com> Feb 06, 2004
- 508 views
----- Original Message ----- From: "Brian Broker" <bkb at cnw.com> To: <EUforum at topica.com> Subject: RE: Displaying HTML > > > Not true on XP... typing a file name in a cmd window will open it using > it's associated application. However, it's unwise to assume everybody's > running XP... > > -- Brian Thanks Brian. I've yet to use an XP system, but I understand that the 'DOS' environment is much more intergrated into the whole OS. -- Derek
12. Re: Displaying HTML
- Posted by "Elliott S. de Andrade" <quantum_analyst at hotmail.com> Feb 09, 2004
- 485 views
>From: Derek Parnell <ddparnell at bigpond.com> >Subject: Re: Displaying HTML > >----- Original Message ----- >From: "Isaac Raway" <isaac-topica at blueapples.org> >To: <EUforum at topica.com> >Subject: Re: Displaying HTML > > > > > Juergen Luethje wrote: > > <snip> >What *API* are you talking about? The EUPHORIA routine called "system_exec" >has nothing to do with any Windows API. It is equivalent to opening a DOS >window and typing in the parameter at the DOS prompt. Thus >'system_exec("ReadMe.html", 2)' is like typing "ReadMe.html" at a DOS >prompt. IT does NOT open a browser to display the html file. If you read >the Euphoria documentation for this routine it says that the parameter >"must be a command to run an executable program" - and a HTML file is not >one of those. > Perhaps you should use system("start ReadMe.html", 2). > >-- >Derek >
13. Re: Displaying HTML
- Posted by "Hayden McKay" <hmck1 at dodo.com.au> Feb 09, 2004
- 536 views
Yes, I have a copy of system_exec() that executed and opened a *.html file from within Judith's IDE 0.18.3 in a mebu item procedure. If u guys like, I can get a copy of it from my brother. SO I MUST SAY U can open a [html] file with syaten_exec() from an [exw] ----- Original Message ----- From: "Elliott Sales de Andrade" <quantum_analyst at hotmail.com> To: <EUforum at topica.com> Sent: Monday, February 09, 2004 3:19 PM Subject: Re: Displaying HTML > > > >From: Derek Parnell <ddparnell at bigpond.com> > >Reply-To: EUforum at topica.com > >To: EUforum at topica.com > >Subject: Re: Displaying HTML > >Date: Sat, 7 Feb 2004 10:20:57 +1100 > > > >----- Original Message ----- > >From: "Isaac Raway" <isaac-topica at blueapples.org> > >To: <EUforum at topica.com> > >Sent: Saturday, February 07, 2004 10:01 AM > >Subject: Re: Displaying HTML > > > > > > > > Juergen Luethje wrote: > > > > <snip> > >What *API* are you talking about? The EUPHORIA routine called "system_exec" > >has nothing to do with any Windows API. It is equivalent to opening a DOS > >window and typing in the parameter at the DOS prompt. Thus > >'system_exec("ReadMe.html", 2)' is like typing "ReadMe.html" at a DOS > >prompt. IT does NOT open a browser to display the html file. If you read > >the Euphoria documentation for this routine it says that the parameter > >"must be a command to run an executable program" - and a HTML file is not > >one of those. > > > > Perhaps you should use system("start ReadMe.html", 2). > > > > >-- > >Derek > > > > > > TOPICA - Start your own email discussion group. FREE! > > > -- > Incoming mail is certified Virus Free. > Checked by AVG anti-virus system (http://www.grisoft.com). > Version: 6.0.580 / Virus Database: 367 - Release Date: 6/02/04 > --- --