Thanks indeed Manish. It worked successfully with me, and I started now working on changing data already exist in the XML .

 

Best wishes for you,

Ahmed.

 

 


From: [email protected] [mailto:[email protected]] On Behalf Of Manish Jethani
Sent: Sunday, August 07, 2005 12:25 PM
To: [email protected]
Subject: Re: [flexcoders] Working with Flex and ASP {Code}

 

On 8/7/05, Ahmed <[EMAIL PROTECTED]> wrote:

> As you can see below, the AddContact.html page posts data to the
> processAdd.asp page.

> My questions are:
>
> Q1: How can we create a MXML page that do the same function of this HTML
> page ?

Using HTTPService, you can post data to your ASP script.

<mx:HTTPService id="myService" url="">
  method="POST" fault="alert(event.fault.faultstring);"
  result="alert('HTTPService responded!')">
  <mx:request>
    <firstName>{model.firstName}</firstName>
    <lastName>{model.lastName}</lastName>
  </mx:request>
</mx:HTTPService>

<mx:Model id="model">
  <firstName>{firstNameInput.text}</firstName>
  <lastName>{lastNameInput.text}</lastName>
</mx:Model>

<mx:Form>
  <mx:FormItem label="First name">
    <mx:TextInput id="firstNameInput" />
  </mx:FormItem>
  <mx:FormItem label="Last name">
    <mx:TextInput id="lastNameInput" />
  </mx:FormItem>
  <mx:FormItem>
    <mx:Button label="Submit" click="myService.send()" />
  </mx:FormItem>
</mx:Form>

...

Read the docs on HTTPService.

Manish



--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com




SPONSORED LINKS
Computer software testing Macromedia flex Development
Software developer


YAHOO! GROUPS LINKS




Reply via email to