accessing asp page from aspx page
-
Hi buddies, I've an classic asp script which accepts an xml as parameter and after processing, it returns an xml, which was used by vb6. Now thing is, I want to do same thing from an aspx page. I was using MSXML2.XMLHTTP in vb6 but when i use this in aspx, it gives an error something like unknown protocol, when i call send method. I'm using .open("GET","URL",false) and then .send. Please anybody tell me, what is the problem and how i can do this with aspx. neerajkumar
-
Hi buddies, I've an classic asp script which accepts an xml as parameter and after processing, it returns an xml, which was used by vb6. Now thing is, I want to do same thing from an aspx page. I was using MSXML2.XMLHTTP in vb6 but when i use this in aspx, it gives an error something like unknown protocol, when i call send method. I'm using .open("GET","URL",false) and then .send. Please anybody tell me, what is the problem and how i can do this with aspx. neerajkumar
Neeraj, You can use
System.Net.WebRequest
(Managed Classes) for the same. Vasudevan Deepak Kumar Personal Web: http://www.lavanyadeepak.tk/ I Blog At: http://www.dotnetjunkies.com/weblog/deepak/
http://deepakvasudevan.blogspot.com/
http://deepak.blogdrive.com/ -
Neeraj, You can use
System.Net.WebRequest
(Managed Classes) for the same. Vasudevan Deepak Kumar Personal Web: http://www.lavanyadeepak.tk/ I Blog At: http://www.dotnetjunkies.com/weblog/deepak/
http://deepakvasudevan.blogspot.com/
http://deepak.blogdrive.com/Thanks deepak, I've tried this. I'm using the same method. code is: Dim myRequest As WebRequest = WebRequest.Create(Server.MapPath("test.asp")) Dim myResponse As WebResponse = myRequest.GetResponse() Dim responseStream As System.IO.Stream = myResponse.GetResponseStream() Dim reader As New System.IO.StreamReader(responseStream) TextBox1.Text = reader.ReadToEnd() myResponse.Close() it shows me this result: <% response.write("Hello")%> and if I try to access remote page then it gives error that connection has lost. can you please help me? thanks again.