Try this...

*

public var uploadURL:String = "path to your servlet" ;
public var fileRef:FileReference = new FileReference();


private function uploadFile():void {
             var request:URLRequest = new URLRequest(uploadURL)
             var variable:URLVariables = new URLVariables();
             variable.Name = NameTxt.text;
             variable.Key = KeywordsTxt.text;
             variable.Desc = DescTxt.text;
             request.data = variable;
             request.method="POST";
                fileRef.upload(request);
}*






On Mon, Nov 10, 2008 at 5:07 PM, harshagalla <[EMAIL PROTECTED]> wrote:

>
> Hi all,
> I am new to using flex
> Im working on  a application where the front end makes a post request
> to the servlet.
> I don't know how to set the URL in the httpservice call.
> In a web java project in which front end was a basic html page with a
> form to be posted to the servlet, the URL was given just as "/
> PrefetchService/PrefetchServiceServlet" which is the location of the
> servlet; but what I dont understand is the same representation for
> httpservice url in flex does not send a call to the servlet. Though
> this could be done by giving the entire URL to the location of the
> servlet, the server on which the project is run changes regularly and
> so either I need to dynamically generate the URL and then make a http
> service call (or) there should be some way to handle calls to a
> servlet in the same project . I would like to know how I could get rid
> of this problem.
>
> Thanks in advance....
>
> >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Flex 
India Community" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/flex_india?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to