[flexcoders] ASP.NET .ashx handler - POST variables not working

2009-05-08 Thread Matthew A. Wilson
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.



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();

...
...

}





[flexcoders] Tile control: Border style and Zoom

2009-04-12 Thread Matthew A. Wilson
I'm using a tile control to display an image with a short description to the 
right of it. Basically everything is contained with in an HBox and the I'm 
programmtically adding that to the tile: 

thisTile.addchild(myHBox)

I'd like to have some sort of visual indicator to let the user know which item 
they clicked on. Whether that be a red border, or a "glow" effect, or whatever.

My question is, how do I do that? I don't see an easy way of setting that in 
any sort of item clickevent. Also, I wanted to have some sort of Zoom or 
magnifier so that when they hovered over the image it would be bigger...but can 
I do that? If I set the width/height on my hbox to 300/100 and then add that as 
an item to my Tile...can I create some sort of zoom or magnify effect whereby 
that image would be larger than the confines of its parent?

Thanks in advance - you all are always so helpful!



[flexcoders] What's your favorite Tip/Trick ?

2009-04-10 Thread Matthew A. Wilson
I've been using .NET for years and recently started developing in Flex. One 
thing I've noticed (and maybe it's because I'm new) is that I have to write out 
just about everything. There were so many things in .NET that the IDE would 
handle for me. Like I could write a function, like DoThis(), and then 
right-click on DoThis() and the IDE would ask me if I wanted to generated a 
method stub. I know that's not earth-shattering, but there were a few things 
here...a few things there that shaved off some seconds and/or minutes and just 
generally speed up development.

I haven't run across anything like that in the FlexBuilder IDE - so my question 
is: What's your favorite tip/trick for speeding up development? Do you have 
some favorite text snippets that you keep handy? Or do you you know some trick 
in the IDE that will save me some repetition?

Or better yet, is there a site or list out there that covers this topic? Thanks 
to all! Have a great weekend!



[flexcoders] Re: Debugger won't break on HTTP Service result function

2009-04-09 Thread Matthew A. Wilson
Well, I figured it out. I'm fairly new to Flex so please hold your laughter. 
What happened is that I was calling 3 HTTPService requests to the database and 
then calling an internal function to work with the data I had received. What I 
didn't realize was that Flex makes those calls asynchronously (I know, I know - 
stop laughing).

So, I was hitting an error in my internal function because it was trying to 
work with an XMLListCollection that hadn't been populated yet (it was null). I 
would put a breakpoint in my result function, but of course, the Flex app had 
already tripped up before the results were returned.

So now I'm "daisy-chaining" my HTTPServices so that the 2nd one is called from 
within the 1st calls result function. And the 3rd within the 2nd, and then 
finally calling my internal function from within the 3rd result function...if 
that makes any sense.

Anyway, thanks for everyone's help. Have a great day!

--- In flexcoders@yahoogroups.com, "valdhor"  wrote:
>
> Have you set up another event listener (using Actionscript) that is grabbing 
> that event?
> 
> 
> --- In flexcoders@yahoogroups.com, "Matthew A. Wilson"  wrote:
> >
> > I have a component that I'm adding to my Flex project and it makes 3 HTTP 
> > Service calls. On the result="" I have listed a function and inside that 
> > function I have created a breakpoint.
> > 
> > When I go into debug, it won't stop at that breakpoint. It's like it's not 
> > calling the result function. I know that the app is making the calls and 
> > getting the resulting XML (using Firebug). I can set a breakpoint anywhere 
> > else in the app and it will stop...just not on the result or fault HTTP 
> > service functions.
> > 
> > Also, I only have this problem on this one component. This doesn't happen 
> > anywhere else in the application. I would paste some code in here for you 
> > to evaluate - but I doubt it will be useful. If I change the name of the 
> > function in the result="" then Flex warns me that I'm referencing a 
> > function that doesn't exist. So when I retype it to match the function 
> > below...the warning disappears.
> > 
> > The only other thing I can mention is that I "accidentally" installed Flash 
> > 10 player, so I uninstalled and then installed Flash 9 Active-X Debugger. 
> > But again...I only have this issue on one component.
> > 
> > Any initial thoughts/ideas?
> > 
> > Thanks to all!
> >
>




[flexcoders] Debugger won't break on HTTP Service result function

2009-04-08 Thread Matthew A. Wilson
I have a component that I'm adding to my Flex project and it makes 3 HTTP 
Service calls. On the result="" I have listed a function and inside that 
function I have created a breakpoint.

When I go into debug, it won't stop at that breakpoint. It's like it's not 
calling the result function. I know that the app is making the calls and 
getting the resulting XML (using Firebug). I can set a breakpoint anywhere else 
in the app and it will stop...just not on the result or fault HTTP service 
functions.

Also, I only have this problem on this one component. This doesn't happen 
anywhere else in the application. I would paste some code in here for you to 
evaluate - but I doubt it will be useful. If I change the name of the function 
in the result="" then Flex warns me that I'm referencing a function that 
doesn't exist. So when I retype it to match the function below...the warning 
disappears.

The only other thing I can mention is that I "accidentally" installed Flash 10 
player, so I uninstalled and then installed Flash 9 Active-X Debugger. But 
again...I only have this issue on one component.

Any initial thoughts/ideas?

Thanks to all!



[flexcoders] Bind ComboBox to returning XML (HOW TO)

2009-03-23 Thread Matthew A. Wilson
Need help with a combobox...

I have a combobox that I want to load from a database. The text will be a name, 
and the value will be an integer.

That's it - pretty straightforward. Just can't seem to figure it out. The xml 
will look like this:


  
  


Thanks so much in advance for your help!!!