Active Server Pages

Moderators: None (Apply to moderate this forum)
Number of threads: 1751
Number of posts: 4473

This Forum Only
Post New Thread
Single Post View       Linear View       Threaded View      f

Report
Reading sent string using POST method in ASP Posted by gangar on 21 Apr 2008 at 10:36 AM
Hello,

I am VC++ programmer. I am novice to ASP. I am using CWebBrowser2(ActiveX control) to navigate some user-written ASP pages from my application. When I navigate from my CWebBrowser2 control, I am telling it to use POST transaction instead of GET transaction and sending some Post data string.

The problem is I don't know correct way how to read this data in ASP. I used Request method but no use. Offcourse, I am not sure 100% that my activeX control is really using POST method to send data correct way. Can somebody help me to read post data. Or is there a way to monitor IIS to see how the activex control sending the request ?
FYI: I am sending string : "MYInput=This is my input"

Thanks.
Report
Re: Reading sent string using POST method in ASP Posted by Flakes on 21 Apr 2008 at 10:08 PM

You can use Request("X") to get the values using either POST or GET method.

Theoretically, the values submitted using GET is accessed using Request.QueryString("X")

And for posted data, it is Request.Form("X").

But using just Request("X"), you can access the value of X, either using POST or GET.

If that doesn't work, show code.

Report
Re: Reading sent string using POST method in ASP Posted by gangar on 22 Apr 2008 at 8:40 AM
:
: You can use Request("X") to get the values using either POST or GET
: method.
:
: Theoretically, the values submitted using GET is accessed using
: Request.QueryString("X")
:
: And for posted data, it is Request.Form("X").
:
: But using just Request("X"), you can access the value of X, either
: using POST or GET.
:
: If that doesn't work, show code.
:
:
The activeX control from C++ is posting data in binary. I am able to read the data in ASP using
Response.BinaryWrite(Request.BinaryRead(Request.TotalBytes))

Is there any easy way to read or convert it into string in my ASP?

I tried Request.Form("X") and Request("X") but no help.
Report
Re: Reading sent string using POST method in ASP Posted by Flakes on 22 Apr 2008 at 10:00 PM



 

Recent Jobs

Official Programmer's Heaven Blogs
Web Hosting | Browser and Social Games | Gadgets

Popular resources on Programmersheaven.com
Assembly | Basic | C | C# | C++ | Delphi | Flash | Java | JavaScript | Pascal | Perl | PHP | Python | Ruby | Visual Basic
© Copyright 2011 Programmersheaven.com - All rights reserved.
Reproduction in whole or in part, in any form or medium without express written permission is prohibited.
Violators of this policy may be subject to legal action. Please read our Terms Of Use and Privacy Statement for more information.
Operated by CommunityHeaven, a BootstrapLabs company.