Archived

This topic is now archived and is closed to further replies.

walkingcarcass

HTML output from another language

Recommended Posts

walkingcarcass    116
My app has some text output which needs to be formatted. It would be convenient for me to use HTML tags in the text stream and use the default browser to show it in a popup window. How is this going to happen? ******** I am not the Iraqi information minister. GSACP : GameDev Society Against Crap Posting To join: Put these lines in your signature and don''t post crap!

Share this post


Link to post
Share on other sites
azimuth    122
You could do it by using WinSock to listen on internet port 80. Then you could enter the url http://localhost/ to get to your application.

That said, it''d probably be much easier to just draw some text in a window.

Share this post


Link to post
Share on other sites
Alimonster    185
Write the stuff out to a temporary file, ShellExecute or CreateProcess, WaitForSingleObject (if required, i.e. if you want the person to close the popup window first), then delete the temp file at some point. That should work, no?

Share this post


Link to post
Share on other sites
walkingcarcass    116
Do we know the name of the window class used for popup adverts? That would probably work a treat.

Edit: this is an interesting example. The home_page() function appears to dump HTML to the default browser, but I don't really understand the code well enough to pick out the relevant parts.

********


I am not the Iraqi information minister.


RESIST!

[edited by - walkingcarcass on August 13, 2003 11:08:10 AM]

Share this post


Link to post
Share on other sites
superpig    1825
Simply writing out a .HTML file and then launching it (I think ShellExecute, when used on a document, will open the app required to view it, won't it?) would probably be easiest... plus the text is then already on disk so you don't need to have the user save it down.

Edit: Oh, or you could look into the MSHTML component; you could display the text from within your application that way, but it would always be using the IE components.

Superpig
- saving pigs from untimely fates, and when he's not doing that, runs The Binary Refinery.
Enginuity1 | Enginuity2 | Enginuity3 | Enginuity4

[edited by - Superpig on August 13, 2003 11:26:15 AM]

Share this post


Link to post
Share on other sites
walkingcarcass    116
You''re misunderstanding. I want to dynamically update the HTML of a web page.

I think the "Internet Explorer_Server" class is the one that actually does HTML rendering. I''m also considering "CabinetWClass". Can I reliably create and use one? Google isn''t very cooperative with the WM_USER+X messages, and most useful results seem to be Delphi and MFC.

Comments? Suggestions?

********


I am not the Iraqi information minister.


RESIST!

Share this post


Link to post
Share on other sites