Forward a page

  • Thread starter Thread starter Chris Calzaretta
  • Start date Start date
C

Chris Calzaretta

Hello guys,
I am using vb.net along with asp.net so I will post this in both areas.

I need to take an internal intrnet page and redisplay it to the internet.

Where would I look to start to do this.
It is possible to read Http stream and redisplay it?

if you have a sample or a good link to a web page that would be great
thanks

Chris
 
Chris,

Although you display it, is a webpages based on a request and a response.
To force to show another page you can use, response.redirect

I hope this helps,

Cor
 
It can not be a redirect. I need to read the html page and redisplay that
page in asp.net/vb.net
 
This is what i am trying to do review code below
Dim req As HttpWebRequest = WebRequest.Create(Me.DropDownList1.SelectedItem.Text)

Try

'Get the data as an HttpWebResponse object

Dim resp As HttpWebResponse = req.GetResponse()

'Convert the data into a string (assumes that you are requesting text)

Dim sr As New StreamReader(resp.GetResponseStream())

Dim results As String = sr.ReadToEnd()

sr.Close()

Response.Write(results)

Catch wex As WebException

Response.Write("<font color=red>SOMETHING WENT AWRY!<br />Status: " & wex.Stat"Message: " & wex.Message & "</font>")

End Try
 
Chris,

Why than don't you write the page as a guid.htm on your webserver and redirect that one.

Cor
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top