HTTPService: How can I send a variable or call a function in it?

Ok i have the following HTTPService request:
<mx:HTTPService id="userRequest" url="
http://mywebsite/get_data.php"
useProxy="false" method="POST">
<mx:request xmlns="">
<user1>{username.text}</user1>
</mx:request>
</mx:HTTPService>
Pretty straight forward stuff there. EXCEPT... i want to use
a variable instead of 'username.text...
<user1>{UserNameList[0]}</user1>
OR i want to be able to call a function that will return the
results such as:
<user2>{ UserFunction() }</user2>
Of course, neither of these work and this makes me sad :(
Anyone have any ideas? Much appreciated~!

on that i can't help
i'm a .net programmer an i use a lot httpservices but mostly
i use webservices to get my data.
But i can give my way of working. When you send your data
from flex you are sending a virtual xml file thru http, then in
.net using it xml class i read this stream of xml coming from flex,
go to my database, get the result , wrapped it in xml and send thru
stream again, so that flex understands the answer. When it gets to
flex i just use e4x to read my data.
There are tons of tutorials on the net for PHP, i wish i had
half for .Net :D

Similar Messages

  • Using action script 2 how can i send a variable value to a dynamic textbox on a different keyframe?

    using action script 2 how can i send a variable value to a dynamic textbox on a different keyframe?

    Thanks for your swift response.
    That sounds like a good solution, but the code I have on frame 2 is this
    timer = 0;
    countup = function(){
    timer++;
    countupInterval = setInterval(countup,100);
    If I added the same actionscript to frame 3 which has a dynamic textbox with a variable timer attached wouldn't it just put the timer back to 0? What I want is the last known value that was given when it was in frame 2.
    I am thinking of temple run here, I am trying to caculate the total distance(set in the timer variable) from the previous try.
    Hope this makes sense.
    Chazwick

  • How can I access JSP variables from a JavaScript function in a JSP page?

    Respected sir
    How can I access JSP variables from a JavaScript function in a JSP page?
    Thanx

    You may be get some help from the code below.
    <%
        String str="str";
    %>
    <script>
        function accessVar(){
           var varStr='<%=str%>';
           alert(varStr);// here will diplay 'str'
    </script>

  • How can I send a parameter to a RFC function in c++ code (in eDM develop)?

    Hi,
    I am expanding Easy Document Management 6 SP14 via c++ code and I am trying to send a parameter value to a RFC function.
    I have succeeded calling a RFC function that requires no parameters.
    I have a pointer that points to the function, but I couldn't find a way to point to the parameter and send a value to it.
    I will appreciate any help (and code example if possible).
    Thanks,
    Eitam

    Hi guys,
    unfortunately I coulden't send parameters to RFC functions as you all described (get the message "This function is not yet implemented" when using Rfc->Field...), so I chose to follow SAP note 821930 which describes how to do something similar in ABAP code (I only need the selected document parameters).
    The problem is that in my code I open SAP gui (as I did in my c++ code: pRfc->InitFunction(L"MyRfcFunction",VARIANT_TRUE),
    but now I don't know how to send the connection parameters from easyDMS to my ABAP function that perform the "call transaction" method.
    my code:
    FUNCTION Z_EASYDMS_FUNCT_GET_LIST. (from note 821930)
    ""Local Interface:
    *" TABLES
    *" DOCUMENTS STRUCTURE BAPI_DOC_FILES2 OPTIONAL
    *" EXT_FUNCTIONS STRUCTURE ZEASYDMS_EXT_FUNC OPTIONAL
    ext_functions-functioncode = 'Z_MY_FUNCTION'.
    ext_functions-displayname = 'Add Doc To Project'.
    APPEND ext_functions TO ext_functions.
    ENDFUNCTION.
    FUNCTION z_easydms_funct_called. (from note 821930)
    ""Local Interface:
    *" IMPORTING
    *" VALUE(FUNCTIONCODE) LIKE SY-UCOMM OPTIONAL
    *" EXPORTING
    *" VALUE(RETURN) TYPE BAPIRET2
    *" TABLES
    *" DOCUMENTS STRUCTURE BAPI_DOC_FILES2 OPTIONAL
    IF functioncode = 'Z_MY_FUNCTION'.
    CALL FUNCTION 'Z_MY_FUNCTION'.
    ENDIF.
    ENDFUNCTION.
    FUNCTION Z_MY_FUNCTION.
    call transaction 'CJ20N'
    ENDFUNCTION.
    now nothing happens, but if I run first my old c++ code (from easyDMS context menu I choose what I've created in c++ which basically does "pRfc->InitFunction(L"MyRfcFunction",VARIANT_TRUE)" ) and then run the implementation above from the context menu it will work (the sap gui will open because it gets the connection parameters from the c++).
    Thanks for your help,
    Eitam

  • How can i store a variable to a file?

    for some reason i can't find much on writing to files, is
    this not possible?
    and if it isnt possible, how can i keep a variable? i don't
    want the variable to reset to 0 every time someone loads a new
    instance of the page.
    also, for some reason.. it seems to me that if statements
    dont work as they should. the vote() function always executes the
    countVote() function even if choice doesn't = ans.
    anyone know what im doing wrong
    example..
    private function vote(choice):void {
    text1.text=choice
    if (choice=ans){
    countVote();
    private function countVote():void {
    total=total+1
    totalS=total.toString();
    text2.text=totalS
    text2 displays the total count and every time i submit the
    vote, the count goes up no matter what i choose
    i also get a warning for all of the variables saying
    "1084: var 'total' will be scoped to the default namespace:
    sv1: internal. It will not be visible outside of this package."
    (sv1 is the name of the project)
    how to i make it visible outside of the package?

    In this case, the if statement will not work as you intended.
    You need to use the double-equals, ie, if (choice == ans)
    Also, the flash player is inside a sandbox for security
    reasons. Consequently, you can not write directly to files. To get
    around this, make a call to a php, python, java or .net script
    residing on the webserver that will write to a file for you. You
    can do this using the HTTPService object.

  • HOW CAN I SEND FIELD SYMBOL TO SUBROUTINE

    HAI,
             HOW CAN I SEND FIELD SYMBOL TO SUBROUTINE
             HOW CAN I COME BACK FROM 5TH INTERACTIVE REROT TO 2ND
    INTERACTIVE REPORT.
    THANK YOU.
    ASHOK

    Hi
    Write some code in the program to come to 2nd list from 5th list
    if sy-lsind = 5.
       sy-lsind = 2.
    endif.
    for field symbols see the doc
    Field Symbols
    Field symbols are placeholders or symbolic names for other fields. They do not physically reserve space for a field, but point to its contents. A field symbol cam point to any data object. The data object to which a field symbol points is assigned to it after it has been declared in the program.
    Whenever you address a field symbol in a program, you are addressing the field that is assigned to the field symbol. After successful assignment, there is no difference in ABAP whether you reference the field symbol or the field itself. You must assign a field to each field symbol before you can address the latter in programs.
    Field symbols are similar to dereferenced pointers in C (that is, pointers to which the content operator * is applied). However, the only real equivalent of pointers in ABAP, that is, variables that contain a memory address (reference) and that can be used without the contents operator, are reference variables in ABAP Objects.
    All operations programmed with field symbols are applied to the field assigned to it. For example, a MOVE statement between two field symbols moves the contents of the field assigned to the first field symbol to the field assigned to the second field symbol. The field symbols themselves point to the same fields after the MOVE statement as they did before.
    You can create field symbols either without or with type specifications. If you do not specify a type, the field symbol inherits all of the technical attributes of the field assigned to it. If you do specify a type, the system checks the compatibility of the field symbol and the field you are assigning to it during the ASSIGN statement.
    Field symbols provide greater flexibility when you address data objects:
    If you want to process sections of fields, you can specify the offset and length of the field dynamically.
    You can assign one field symbol to another, which allows you to address parts of fields.
    Assignments to field symbols may extend beyond field boundaries. This allows you to address regular sequences of fields in memory efficiently.
    You can also force a field symbol to take different technical attributes from those of the field assigned to it.
    The flexibility of field symbols provides elegant solutions to certain problems. On the other hand, it does mean that errors can easily occur. Since fields are not assigned to field symbols until runtime, the effectiveness of syntax and security checks is very limited for operations involving field symbols. This can lead to runtime errors or incorrect data assignments.
    While runtime errors indicate an obvious problem, incorrect data assignments are dangerous because they can be very difficult to detect. For this reason, you should only use field symbols if you cannot achieve the same result using other ABAP statements.
    For example, you may want to process part of a string where the offset and length depend on the contents of the field. You could use field symbols in this case. However, since the MOVE statement also supports variable offset and length specifications, you should use it instead. The MOVE statement (with your own auxiliary variables if required) is much safer than using field symbols, since it cannot address memory beyond the boundary of a field. However, field symbols may improve performance in some cases.
    check the below links u will get the answers for your questions
    http://help.sap.com/saphelp_nw04/helpdata/en/fc/eb3860358411d1829f0000e829fbfe/content.htm
    http://www.sts.tu-harburg.de/teaching/sap_r3/ABAP4/field_sy.htm
    http://searchsap.techtarget.com/tip/1,289483,sid21_gci920484,00.html
    Syntax Diagram
    FIELD-SYMBOLS
    Basic form
    FIELD-SYMBOLS <fs>.
    Extras:
    1. ... TYPE type
    2. ... TYPE REF TO cif
    3. ... TYPE REF TO DATA
    4. ... TYPE LINE OF type
    5. ... LIKE s
    6. ... LIKE LINE OF s
    7. ... TYPE tabkind
    8. ... STRUCTURE s DEFAULT wa
    The syntax check performed in an ABAP Objects context is stricter than in other ABAP areas. See Cannot Use Untyped Field Symbols ad Cannot Use Field Symbols as Components of Classes.
    Effect
    This statement declares a symbolic field called <fs>. At runtime, you can assign a concrete field to the field symbol using ASSIGN. All operations performed with the field symbol then directly affect the field assigned to it.
    You can only use one of the additions.
    Example
    Output aircraft type from the table SFLIGHT using a field symbol:
    FIELD-SYMBOLS <PT> TYPE ANY.
    DATA SFLIGHT_WA TYPE SFLIGHT.
    ASSIGN SFLIGHT_WA-PLANETYPE TO <PT>.
    WRITE <PT>.
    Addition 1
    ... TYPE type
    Addition 2
    ... TYPE REF TO cif
    Addition 3
    ... TYPE REF TO DATA
    Addition 4
    ... TYPE LINE OF type
    Addition 5
    ... LIKE s
    Addition 6
    ... LIKE LINE OF s
    Addition 7
    ... TYPE tabkind
    Effect
    You can define the type of the field symbol using additions 2 to 7 (just as you can for FORM parameters (compare Defining the Type of Subroutine Parameters). When you use the ASSIGN statement, the system carries out the same type checks as for USING parameters of FORMs.
    This addition is not allowed in an ABAP Objects context. See Cannot Use Obsolete Casting for FIELD SYMBOLS.
    In some cases, the syntax rules that apply to Unicode programs are different than those for non-Unicode programs. See Defining Types Using STRUCTURE.
    Effect
    Assigns any (internal) field string or structure to the field symbol from the ABAP Dictionary (s). All fields of the structure can be addressed by name: <fs>-fieldname. The structured field symbol points initially to the work area wa specified after DEFAULT.
    The work area wa must be at least as long as the structure s. If s contains fields of the type I or F, wa should have the structure s or at least begin in that way, since otherwise alignment problems may occur.
    Example
    Address components of the flight bookings table SBOOK using a field symbol:
    DATA SBOOK_WA LIKE SBOOK.
    FIELD-SYMBOLS <SB> STRUCTURE SBOOK
    DEFAULT SBOOK_WA.
    WRITE: <SB>-BOOKID, <SB>-FLDATE.
    Related
    ASSIGN, DATA
    Additional help
    Declaring Field Symbols
    Reward points if useful
    Regards
    Anji

  • How can we send a collection object to server?

    Hi All
    I am beginner in Flex. I have an assignment to do, plz help
    in this.
    How can we send a collection object to server?
    Means:
    I have a list of user details in a grid.
    And if i want to add a new User or edit a existing user
    details then i don’t want to send a request every time.
    Instead of i want to keep adding new User only in front side
    i.e. in the grid
    And finally i will send a single request with all the Users
    details.
    can it be possible ? If possible please help me.
    Thanks in advance

    Actually, the best way to do is using amfphp but since you
    are new to flex it might be a bit confusing if you dont know php.
    check here for amfphp:
    http://www.amfphp.org/
    you can also traverse through the arraycollection and create
    and xml. (this part is basic programming). Then you can send it to
    server using a post.
    For that think check the liveDocs for classes:
    HTTPService
    and
    URLLoader.

  • How can I send email using two different email address that both link back to my one exchange account on my Ipad mini

    How can I send email using two different email address that both link back to my one exchange account on my Ipad mini? 
    On my PC I simply have a master return email address and use a POP for the secondary address.  Both are through the one exchange account without a problem.  I need to be able to do the same on my Ipad.

    Ah, I should have made that clear.  My domain didn't come from google.  It was purchased at and is hosted at dreamhost, but I haven't used their email servers in years - I just route everything through gmail.  I actually have a bunch of domains (with websites).
    Gmail has an option that lets someone with custom domains send (and receive) email through gmail using the custom domain once Google confirms proper ownership of the domain (to prevent spammers and such).  Gmail has a setting for "send email as" which allows gmail to be sent using a custom domain as the sender.  I'm pretty sure Apple's old mobileme had this feature too, but I didn't use it.

  • How can I send stuff from one iPhone to another via Bluetooth?

    How can I send stuff from one iPhone to another via Bluetooth?

    There are some apps that will let you send photos from one iOS device to another over BT.

  • How can I send email from my yahoo alias account in iPhone5 mail?

    How can I send email from my yahoo alias account in iPhone5 mail?
    I have 2 email accounts: [email protected] is an alias of [email protected]
    In my old iPhone3 I had these accounts set up so that I could send and receive email from both accounts. I did this using the following settings:
    ‘Other’ POP account info:
    Name: xyz
    Address: [email protected]
    Description: alias
    Incoming mail server:
    Host name: pop.mail.yahoo.com
    User name: [email protected]
    Password: password for yahoo account
    Server port: 995
    Outgoing mail server:
    SMTP: smtp.o2.co.uk (o2 is the name of my phone network)
    Server port: 25
    ‘Yahoo!’ account info:
    Name: xyz
    Address: [email protected]
    Password: password for yahoo account
    Description: Yahoo!
    Outgoing mail server:
    Primary server: Yahoo! SMTP server
    Server port: 465
    I’ve tried using the same settings in my new iPhone5, but it doesn’t work. I can receive mail to both accounts, and can send from the Yahoo account, but I cannot send mail from the alias account. When I try, it displays the message: “Cannot send mail. A copy has been placed in your Outbox. The recipient ‘[email protected]’ was rejected by the server”.
    I’ve tried to configure the POP alias account using combinations of ‘pop.mail.yahoo.com’, ‘pop.mail.yahoo.co.uk’, ‘apple.pop.mail.yahoo.co.uk’ and ‘apple.pop.mail.yahoo.com’, for the incoming host, and ‘smtp.o2.co.uk’, ‘smtp.mail.yahoo.com’, ‘smtp.mail.yahoo.co.uk’, ‘apple.smtp.mail.yahoo.com’ and ‘apple.smtp.mail.yahoo.co.uk’ for the outgoing mail server. None of these have worked.
    I’ve also tried setting it up using IMAP instead of POP without success. I tried configuring it using combinations of ‘imap.mail.yahoo.com’, ‘apple.imap.mail.yahoo.com’, ‘imap.mail.yahoo.co.uk’ and ‘apple.imap.mail.yahoo.co.uk’ for the incoming mail server and ‘smtp.o2.co.uk’, ‘smtp.mail.yahoo.com’, ‘smtp.mail.yahoo.co.uk’, ‘apple.smtp.mail.yahoo.com’ and ‘apple.smtp.mail.yahoo.co.uk’ for the outgoing mail server.
    Yahoo say that if I can't send Yahoo! Mail from my mail program, I may be accessing the Internet through an ISP that is blocking the SMTP port, and that if this is the case, I should try setting the SMTP port number to 587 when sending email via Yahoo!'s SMTP server. I don't think that this is the problem, but I tried it just to make sure - without success.
    I’ve also heard that the problem might have something to do with the SPF settings of my alias domain provider. I’m not too sure exactly what SPF settings are, or how to change them, but from what I can gather it seems unlikely that this is the problem given that I was able to send mail from my alias account on my old iPhone3.
    Any help much appreciated: how can I get my alias account to send emails in iPhone5 mail?
    Many thanks,
    Patrick

    A new development: I've tried sending emails from the alias several times over the past 24 hours, but in general I've deleted them if they haven't sent within about half an hour.
    However, one of the messages I left sitting in the outbox did send successfully in the end, but this took about an hour.
    So: perhaps my problem is not in fact that I am completely unable to send mail from my alias, but that I can only do so intermittently and extremely slowly, and by ignoring the "cannot send" message.
    Any help appreciated.

  • How can we send Error Idocs via mail

    Hi,
    I have read read through forums and  understood that it can be achieved either through workflow or through report using table edidd & edids.
    If workflow option is used , does the mail trigger for every error idoc ? How can we send daily error report to user say by EOD containing all error idocs using all possible options.
    Regards,
    Rachel

    Rachel,
    I dont think so any direct Report will be available just to get Error IDOCs details. Although you can create a simple report to read the tables. An example is in below link.
    http://wiki.scn.sap.com/wiki/display/Snippets/Custom+report+for+IDOC+Monitoring
    Also, you can create a Query of EDIDC and EDIDS tables to obatin relevant information.
    Thanks,
    Ravi

  • How can I send more than one document on an email

    how can I send more than one document on one email

    Thank you but I understand that form of attaching a document. However when I select a document then click 'Share' I have the option of sending the document by email as a word or pages document or pdf, what I want to know is can I use this procedure to send more than one document per email and if I can how?

  • How can I send more than one foto in a email

    How can I send more than one foto in a email?

    Or, to send up to 5 photos in one email, open the Photos app, go to the Album containing the photos, tap Select, tap up to 5 photos (a blue tick will appear on them), then tap the Share icon (square with arrow pointing up) and choose Mail.
    If you choose more than 5 photos this way, you won't get the Mail option.

  • How can I send multiple photos in an email?

    How can I send multiple photos in an email?

    In Photos, when looking at your pictures, click the Action arrow first (upper right), before selecting any pictures.  Then you can tap select the pictures you want to send then click "Share" in the upper left.  From there you can Email.
    If you click and open one picture first, the Action button will only allow you to share that one picture.
    (Yeah, took me a while to figure this out. )
    ivan

  • How can I send out a voice memo by iphone 6 plus?

    How can I send out a voice memo to my friend? the voice memo last around 1.5 hours.  I tried to sent by email but not success.
    Pls. help.

    It is not Family Sharing - it is Continuity. Go to Settings>FaceTime>Cellular Calls, turn them off.
    Cheers,
    GB

Maybe you are looking for

  • BEx Cell Report - Performance Issue

    All, We have a BEx Report in which I have used cell formulas extensively. My BW ver 3.0B and parch 31. From last f32 weeks this report is working only for maximum of 9 materials. Tthe report output comes very fast. The momemnt I give 10th material or

  • Fi-sl totals and line items

    dear experts, i have timestamp generated for actuals line items table for fi-sl. i also have the totals summary table but it has no timestamp. i like to find out how can i compare records for the 2 tables given that timestamp is not present in totals

  • Url change with servlet to jsp

    Hi, i guess i have a small problem- i am using this code to forward from a servlet to a jsp: protected void passProcessing(String url, HttpServletRequest req, HttpServletResponse res) {           RequestDispatcher rd = req.getRequestDispatcher(url);

  • Overclocking ATI Radeon xpress 1270

    Hi guys I have an msi notebook ER 710 with ATI RADEON XPRESS 1270 and i wonder if I can overclock the vga card. If any body knows how i can overclock it please give me some information and how can it be done? 10x

  • Xi and R/3

    Hi, while doing file to proxy,how is the connection established between XI and R/3?as we go to SPROXY in R/3, we can see all the desgign objects of xi? Thanks, Jhanavi