Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

browsing ASP pages

Status
Not open for further replies.

arlequin

Programmer
Sep 21, 1999
232
UY
Hi people!<br><br>I want to print out (server side) an ASP page:<br><br>ASP --&gt; browses into ---&gt; HTML<br><br>HTML --&gt; prints into ---&gt; PostScript<br><br>PostScript---&gt; generates a ---&gt; PDF File<br><br>the last two actions are solved, but I must print the output generated HTML from my original ASP document.<br>I thought in a VB component that &quot;browses&quot; the ASP and then I can print it out at the server into my PostScript component and so on...<br><br>I am right?<br>I this case... how can I have an ASP docuement &quot;browsed&quot; into a VB COM ?
 
An ASP page is really an HTML page, because when you request an ASP, it automatically returns HTML information, try doing a View Source when you download an ASP.<br><br>an ASP is just like an HTML , only it gets proccessed before it is sent to the client. <br><br>its a bit more than that, but the point is , when it finally replies back tot he client, the result is an HTML page, which is why ASP is compatible with any browser, and OS, because it looks like an HTML to the browser. <p>Karl<br><a href=mailto:kb244@kb244.8m.com>kb244@kb244.8m.com</a><br><a href= </a><br>Experienced in , or have messed with : VC++, Borland C++ Builder, VJ++6(starting),VB-Dos, VB1 thru VB6, Delphi 3 pro, Borland C++ 3(DOS), Borland C++ 4.5, HTML, ASP(somewhat), QBasic(least i didnt start with COBOL)
 
I know all this stuff<br>Thanx anyway, Karl<br><br>I program ASP pages but my question is:<br><br>how can I have the HTML generated FROM SERVER SIDE SCRIPTING, like a VisualBasic Component ???<br><br>I am clear?<br><br>Thanx in advance
 
if you mean how to have HTML tags sent back through a ASP page, well Response.write has always worked for me. <p>Karl<br><a href=mailto:kb244@kb244.8m.com>kb244@kb244.8m.com</a><br><a href= </a><br>Experienced in , or have messed with : VC++, Borland C++ Builder, VJ++6(starting),VB-Dos, VB1 thru VB6, Delphi 3 pro, Borland C++ 3(DOS), Borland C++ 4.5, HTML, ASP(somewhat), QBasic(least i didnt start with COBOL)
 
Hey, You don't sound like a windows guy. How'd you get here?<br>Well, nevermind. If I understand you correctly you want to store the results of an HTTP request in a buffer and then do something with that buffer later on.<br><br>You can create an <i>instance</i> of an 'INetCtl' or just drop an 'INetCtl' <i>control</i> on a form; once done use that control to fire off HTTP requests from your VB app.<br><br>Using the activex Control (easiest to accomplish) it looks kinda like this:<br><br>Form contains a couple of buttons ie. 'Go' and 'Quit', the InetCtl, a text box (for entering the URL) and a <u>RichTextBox</u> control. Still with me?<br><br>O.K., <br><br>Sub FireOffRequest()<br>&nbsp;&nbsp;Dim strBuff as String '<br>&nbsp;&nbsp;'Some code to validate string provided in Text1<br>&nbsp;&nbsp;'before use perhaps.<br>&nbsp;&nbsp;strBuff = InetCtl1.OpenURL Text1.Text<br>End Sub<br><br>Sub Button2_Click()<br>&nbsp;&nbsp;&nbsp;Call FireOffRequest<br>End Sub<br><br>Sub Button1_Click()<br>&nbsp;&nbsp;&nbsp;'GoToLunch! But first close the form.<br>&nbsp;&nbsp;&nbsp;&nbsp;Unload Me<br>End Sub<br><br><br>Whew, that's complicated!<br><br>'strBuff' now contains the HTTP request results (the webpage). Hard to believe...<br><br>' just add the line of code <br>&nbsp;&nbsp;RichTextBox1.Text = strBuff<br>' The (HTML) page appears in the text box.<br><br>Compared to other programming tools & platforms, with VB on Windows OS this type of thing becomes extremely easy to accomplish.<br><br> <p>Amiel<br><a href=mailto:amielzz@netscape.net>amielzz@netscape.net</a><br><a href= > </a><br>
 
there should be an OpenURL command, that would open the URL , holding the returned result (the HTTP reply). <p>Karl<br><a href=mailto:kb244@kb244.8m.com>kb244@kb244.8m.com</a><br><a href= </a><br>Experienced in , or have messed with : VC++, Borland C++ Builder, VJ++6(starting),VB-Dos, VB1 thru VB6, Delphi 3 pro, Borland C++ 3(DOS), Borland C++ 4.5, HTML,Visual InterDev 6, ASP(WebProgramming), QBasic(least i didnt start with COBOL)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top