Well, if you are POSTing from Flex and your ASP.NET is looking at the query
string it will of course not find it.  GET puts content in the query string.
Either change how Flex is sending the data (change it to GET) or change how
your ASP is looking for the data (look at the POST data).

I am not familiar with ASP.NET syntax but in PHP it is the difference
between $_GET and $_POST.

Charles P.



On Fri, May 8, 2009 at 12:47 PM, Matthew A. Wilson <korb...@yahoo.com>wrote:

> I created a web handler (.ashx) in ASP.NET and it takes 4 post variables,
> all strings.
>
> When I manually type in the URL with the variables
> (name=this&email=that&comments=this) it works fine, but when I try to POST
> those variables in an HTTPRequest in Flex, my web handler can't "see" the
> variables. It breaks on the first line and says, there is no "name"
> variable, i.e. - no instance of an object.
>
> What am I doing wrong? Does the Flex Request have to be formatted
> differently for .NET? It works fine in PHP.
>
> <code>
>
> public void ProcessRequest (HttpContext context) {
>        string sName = context.Request.QueryString["name"].ToString();
>        string sEmail = context.Request.QueryString["email"].ToString();
>        string sType = context.Request.QueryString["type"].ToString();
>        string sComment = context.Request.QueryString["comment"].ToString();
>
> ...
> ...
>
> }
>
> </code>
>
>
>
> ------------------------------------
>
> --
> Flexcoders Mailing List
> FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
> Alternative FAQ location:
> https://share.acrobat.com/adc/document.do?docid=942dbdc8-e469-446f-b4cf-1e62079f6847
> Search Archives:
> http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo! Groups
> Links
>
>
>
>

Reply via email to