Passing values from one .mxml file to other

Hi all,
I am a flex newbie, and I have to admit I like flex very much. I have the following question:
I am trying to make a really simple example, where I have a simple mxml application containing some radiobuttons. the radiobuttons simply change the color of several graphic shapes (circles,etc) on click. I am trying to add a new state (represented as a new mxml module) that contains different shapes. Still, I want to pass the value of the originally created radiobuttons to my new state (aka interface view) so that the new shapes inherit their color according to the radiobuttons value (selected:true || false). I am using flex 4 and in order to load my new interface (module) I use the SWFLoader.
Any help would be greatly appreciated. Also, if my (above) description doesn't make sense, I can easily paste my code (it's just a few lines anyway).
Thank you.

I'm not the most experienced flex user, but in other programming languages, each class is usually kept separate and can interact with each other using public functions. You might need to create a function in class B called setColorOfObject(object:object, color:color). Then in class B you can use those values to manipulate objects contained within class B. You would need to call the function contained in class B using class A.
~dan

Similar Messages

  • Passing value from one mxml application to another mxml application

    I am stuck up with a problem.
    what i am doing is i have created a mxml application which has user sign form ,
    this form accepts username and password and calls a remote object method checklogin()
    when it finds correct it must jump to another mxml file after succesful login .
    i have created remote object and i want to know how can we pass the username to another mxml application from the resulthandler function which handles the result for that function. Further i would like to ensure that session is handled correctly , whenever i press F5 or Refresh button after login i redirected to the state where i need to login again.
    plz Sugeest me some solutions..

    hi rajesh......
                       for using 2 components... you should go for component usage.... here is a God given tutorial which will guide you.
    [link|https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/2e71ce83-0b01-0010-11a4-98c28a33195f ]
    ---regards,
       alex b justin

  • How ?? Pass value from one procedure to the others.

    I'm thank you everyone visited my Thread.
    This is my abbreviate program. I've a procedure "proc_check_item" that have many conditions and "proc_item_number" get value (v_stmt)from "proc_check_item".
    -- proc_check_item --
    v_stmt varchar2(100);
    If conditions1 then
    v_stmt := 'and item_number between 1000 and 2000';
    package.proc_item_number(v_stmt);
    elsif conditions2 then
    v_stmt := 'and item_number >= 1000';
    package.proc_item_number(v_stmt);
    elsif
    v_stmt := 'and item_number <= 2000';
    package.proc_item_number(v_stmt);
    end if;
    -- proc_item_number(p_stmt in Varchar2) --
    cursor cur_01 is
    select item_01, ....
    from table_a
    where ...
    and ...
    &v_stmt <--- this point!!!
    How can i do to passed v_stmt from
    "proc_check_item" to "proc_item_number".
    I'm used &,||, ... its does not work pls. help me
    ---- If its right it should be -----
    cursor cur_01 is
    select item_01, ....
    from table_a
    where ...
    and ...
    and item_number between 1000 and 2000
    cursor cur_01 is
    select item_01, ....
    from table_a
    where ...
    and ...
    and item_number >= 1000
    It's look like at REPORT that i can used 'place holder parameter' to support this query but in this procedure !!
    How can i do..
    Thank you for your kindness ...
    Message was edited by:
    Anonymous
    Message was edited by:
    Anonymous

    Something like this:
    -- proc_item_number(p_stmt in Varchar2) --
    cursor cur_01(v_stmnt varchar2) is
    select item_01, ....
    from table_a
    where ...
    and v_stmt = ...
    open cur_01(p_stmt)

  • Passing value from one jsp to another?

    how to pass value from one jsp to another? i have a value assigned in the link, i want to pass that value to another jsp page?
    please help with code?

    Instead of the value being passed, i am getting a null value.
    Here is my calendar code:
    <%@page import="java.util.*,java.text.*" %>
    <html>
    <head>
    <title>Print a month page.</title>
    </head>
    <body bgcolor="white">
    <%
                  boolean yyok = false;
                  int yy = 0, mm = 0;
                  String yyString = request.getParameter("year");
                  if (yyString != null && yyString.length() > 0)
                      try
                          yy = Integer.parseInt(yyString);
                                  yyok = true;
                       catch (NumberFormatException e)
                          out.println("Year " + yyString + " invalid" );
                  Calendar c = Calendar.getInstance( );
                  if (!yyok)yy = c.get(Calendar.YEAR);  
                         mm = c.get(Calendar.MONTH);
    %>
                  <table align="center">
                      <tr>
                  <td>
                       <form method=post action="calendar.jsp">
                          Enter Year : <select name="year">
    <%         
                 for(int i= yy;i<=2010;i++)
    %>
                  <OPTION VALUE= <%=i%> > <%=i%> </option>
    <%       
    %>
              </select>
                      <input type=submit value="Display">
                      </form>
                      </td>
                    </tr>
    <tr>
                     <table>
    <%!
    String[] months = {"January","February","March",
                    "April","May","June",
                    "July","August","September",
                    "October","November", "December"
    int dom[] =     {
                        31, 28, 31, 30,
                        31, 30, 31, 31,
                        30, 31, 30, 31
    %>
    <%
                int leadGap =0;
    %>
    <div id="t1" class="tip"><table border="4" cellpadding=3 cellspacing="3" width="250" align="center" bgcolor="lavender">
    <tr>
    <td halign="centre" colgroup span="7" style="color:#FF0000;">
    </colgroup>
    <tr>
    <td>
    <%
              GregorianCalendar calendar =null;
              for(int j=0;j<12;j++)
                        calendar = new GregorianCalendar(yy, j, 1);
                  int row = 1 ;
                  row = row + j;
        %>
              <table>
                <tr>
              <colgroup span="7" style="color:#FF0000;">
              </colgroup>
                </tr>
              <tr align="center">
              <th colspan=7>
                  <%= months[j] %>
                  <%= yy %>
              </th>
              </tr>
    <tr>
    <td>Sun</td><td>Mon</td><td>Tue</td><td>Wed</td><td>Thu</td><td>Fri</td><td>Sat</td>
    </tr>
    <%
        leadGap = calendar.get(Calendar.DAY_OF_WEEK)-1;
        int daysInMonth = dom[j];
        if ( calendar.isLeapYear( calendar.get(Calendar.YEAR) ) && j == 1)
        ++daysInMonth;
        out.print("<tr>");
        out.print(" ");
          for (int h = 0; h < leadGap; h++)
           out.print("<td>");
          out.print("</td>");
        for (int h = 1; h <= daysInMonth; h++)
          out.print("<td>");
          out.print("<a href=desc.jsp>" + h + "</a>" );
          out.print("</td>");
        if ((leadGap + h) % 7 == 0)
            out.println("</tr>");
    out.println("</tr></table></div>");
    if( row%3 != 0)
    out.println("</td><td>");
    else
    out.println("</td></tr>\n<tr><td>");
    %>
    </html>I need to pass the value in 'h' to the desc.jsp page.
    my code for desc.jsp is :
    <html>
    <head>
    </head>
    <body bgcolor="lightblue">
    <form method=post action="Calenda.jsp">
    <br>
    <%= request.getParameter("h") %>
    <h2> Description of the event <INPUT NAME="description" TYPE=TEXT SIZE=20> </h2>
    <BR> <INPUT TYPE=SUBMIT VALUE="submit">
    </form>
    </body>
    </html>But i am not able to pass the value. The 'h' value contains all the date. i want to pass only a single date, the user clicks to the other page. please help

  • Pass values from one Taskflow to another

    JDev 11.1.1.5.0 ADF BC
    Use case: Need to pass values between two bounded taskflows. There are two different pages on two different taskflows and I need to pass values from one to another.

    Hi sahar
    you can set the value you want to pass to another taskflow in pageFlowScope
    and create input params in the another taskflow and set this pageFlowScope valu into that
    Params of TaskFlow
    you can refer the following link
    http://opreview.blogspot.in/2011/07/adf-how-to-pass-parameters-between.html
    Regards

  • Is there any way to pass value from one SWF to another ?

    I am doing project using flash, now I cant pass a value from one SWF to another, is there any way to pass value from one SWF to another.
    thanks

    Hi,
    Just to confirm here do you simply want to communicate between two SWFs without involving Flash Media Server. If this is the case one good way of doing it is to use a local connection. It can be used for direct communication between two separate instances of the flash player. However if you want to involve multiple clients sharing a common variable then you may have to use Shared Object for this. Please let me know what is the actual use case, is it multiple clients sharing a common variable or different player instances communicating between themselves.
    Thanks,
    Abhishek

  • How to pass Data from one form to the other

    Hi all
    Can any one suggest me how to pass data from one form to the other form, which i zoomed from the original one?
    I tried to do this by passing parameter in Event Procedure but i am getting error msg when i am opening the zoomed form.
    If any one of u have any idea, give me a reply
    Thank you
    Suhasini

    If you choose the second alternative you should erase these global variables after the second form is opened
    You can erase the global variable using:
    erase('global_var')
    Greetings,
    Sim

  • Passing Value from one File to Another !!!

    Hi Friends,
    I have an issue, I have two different Swing programs (two seperate java files). I want to transfer value from one file to the another. Like we do in Servlets or JSP, we use sessions or Hiddenfields. The same way I want to retriev value in a new file from a previous one.
    Hope that all u champs out there have the answer to my query.
    Thanks,
    [email protected]

    This is a B2B comms question...
    A quick and dirty method is to use Socket/ServerSocket and use a basic protocol to do the transfer, if you are feeling heroic then use XML as the message format...
    A lot depends on whether your applications are running on separate boxes, i.e. do you need to communicate across a network...
    If not, if they are always going to be on the same "box" then you could just use well-known places for files...not portable but effective...

  • Pass value from one page to another

    Hi All,
    "How to pass the value from one Flex page to anothere Flex
    page".
    In First Flex page contains One Inputtext and one button is
    there.After entering the data in inputtext box,the user clicks on
    the button then get the data from inputtext box and then i need to
    send that value to another flex page and display there.
    Can u tel me plz............
    Thanks & Regards,
    Nagarjuna.

    I believe you are thinking in terms of HTML and traditional
    page coding. As an old school ColdFusion guy I understand it is
    difficult to leave that behind. (at least it was for me.) Unless
    you literally have two different HTML pages that each have their
    own Flex app running in them you do not need to send data from one
    page to the next like you would with Web Forms. (If you are doing
    that you may want to simply write the data to a Shared Object, Pass
    it to a server to store and then feed back into the second Flex App
    when it loads or perhaps use the ExternalInterface to then pass it
    through as a series of URL parameters that can be loaded into the
    next Flex App.)
    In Flex you do not have to worry about loosing state between
    pages because there are literally no pages. Only different views.
    You would not "Send" the value from one page to another. You
    provide a mechanism for the second view to reference the same model
    or data object (most call them ValueObjects) that the first view is
    setting via the form fields.
    You would want to use a ValueObject in the first VIEW and
    then fill the object with the form data using setter methods on the
    object. For example set the fields onChange event to call the
    setter on the object and pass it the form fields value as the
    property. Alternately you could bind the values of the model
    directly to the fields so that they automatically obtain the data
    that is being filled in.
    Depending on how complex of an application you are going to
    build and how scalable it must eventually be you have many
    different options to choose from to allow the second View to use
    the data set but the first. However to make the application
    ultimately more scalable you are going to want to keep your view
    separated from the controller and that separated from the
    Model/ValueObject. (By seperated I mean in different classes.)
    I would suggest looking up the subject of MVC in Flex and
    also the Mediator Design pattern. There are many great sources of
    information.
    Here are a few links that may help with ideas.
    http://flexblog.faratasystems.com/?p=246
    http://pages.cpsc.ucalgary.ca/~heatond/mediator/
    http://livedocs.adobe.com/flex/3/html/help.html?content=introbd_2.html

  • Pass Value from one tab to another

    Hi,
    I have a requirement to pass a value from one tab to another.
    For ex: I have a CC&B page with two tabs (Main, Steps).
    In the Main tab, I choose a Field Activity. Once it is chosen, I want to pass the value of the Field Activity ID to the 'Steps' tab. Once I get the value of the field Activity, I can then query up a table and populate some fields in the Steps tab. How can i achieve passing the value if FA Id from one tab to another?
    I tried to create an extension of the page using ext_page.jsp. But this extension just provides us methods like extPreOnWindowLoad(), extPostOnWindowLoad() etc which really is not helpful.
    Any suggestions?
    thanks

    Hi,
    We cannot pass multiple values using Drill Filters beause it is based on hierarchy that can take only one value at a time.
    If you want you can use Report Level Filter instead.
    Neither can we pass dril filters from one tab to other.

  • Pass value from one layer to another.

    Hey,
    Is it possible to pass a value from one layer to another.
    I have a text that I'll get from layer 1 and I want to pass the value to a TextArea in layer 3.
    Is it possible, anyone?
    Thanks.

    I cannot be sure what you are calling a layer is what I know to be a layer--normally one does not go to layers, one goes to different frames.  If you look at the timeline, it consists of frames and possibly multiple layers.  Every layer has the same number of frames, and content in frame 1 of one layer is accessible by content in frame 1 of any other layer.  So if you have a textfield in layer 1, frame 1, and you have a textarea in frame 1, layer 2, you can use code to have the text in one of those assigned to the other.
    If you show a picture of what you are trying to describe it may help.

  • Passing value from one program to another

    Dear All,
    I have to pass one value from one program to the standard selection screen .But there is no paramter id .how can i pass the value.
    Regards,
    Magesh

    Hi Magesh,
    See the help for these
    - EXPORT obj1 ... objn TO DATA BUFFER f.
    - EXPORT obj1 ... objn TO MEMORY.
    - EXPORT (itab) TO ... .
    - IMPORT obj1 ... objn FROM DATA BUFFER f.
    - IMPORT obj1 ... objn FROM MEMORY.
    - IMPORT (itab) FROM ... .
    Important thing is that these work correct in same session only.
    awrd points if useful
    Bhupal

  • ESB  : How to Pass value from one RS to another RS

    Hi Gurus,
    I want to pass a value from one First Routing service to another to set the value for the last XSL transformation.
    How can I do this without creating specific XSDs??
    Rgs
    JO

    Data flowing through the ESB is XML-based (or opaque), so if the value you want to pass is in the XML result of RS1, you can use it in RS2. If you have a good reason why not too or this doesn't work for you, you could store data somewhere along the ESB process (database, stateful bean, etc.). Otherwise, you would need to let the ESB generate (or create you own) XSD describing the XML.
    Regards,
    Ronald

  • How to pass value from one method to another method

    Hi all,
    I have created a funtion module and i am calling this function module inside a method and it is exporting some value in a table, now i have to pass table value to another method where i have do some thing based upon this values.
    I think there a marco available to move the values from one method to another method.
    Please help me in this issue.
    Regards
    Balaji E.

    Hi,
    Let me make certain assumptions!
    Method 1 - You export the table values
    Method 2 - The method where you need the table values
    Once you create a method from a function module which has tables as one of the export parameters then the code automatically puts in the macro code which looks like : SWC_SET_TABLE CONTAINER 'Table' TABLE.
    The 'Table' in the above code is the container element which is created by the workflow once you use this method and the TABLE (The table that gets filled in the function module) is the variable to code automatically created.
    Now you can use the other function module in the workflow as a background step and pass the values from the 'Table' container to this method using the binding. When you use this then the method automatically has the macro SWC_GET_TABLE CONTAINER 'Table' ITABLE. Here the 'Table' is the same container table you used in the binding and the ITABLE would be the variable you can use in the other function module.
    Hope this helps,
    Sudhi

  • How can I pass values from one node to another

    Give a standard and efficient way to pass values from child to parent

    hai Prathap
    You can use the custom event  for passing values from child to parent

Maybe you are looking for

  • How to optimize data logging in my code?

    I have my program working well enough to have it run some trials in the lab. It was run under some 'extreme' conditions to make sure data acquisiton and logging is working well. With frequency being 1000Hz, he requirements are that the relay goes ON

  • Initial password change requested with SSO

    Hi all, we have well working SSO with EP6 SP2 and standalone ITS. SSO is based on SAP logon ticket. Only one annoying thing appears. If a new user is created in SAP R/3, ITS asks for changing of password. Does it mean that the user must initially (an

  • My muse website, when uploaded, jumbles quotation marks, bullet points and apostrophes to appear as • and â€? Why?

    My muse website jumbles quotation marks, bullet points and apostrophes to appear as ’. Its fine when I preview in browser, only once it's been uploaded do the marks become jumbled. Why?

  • Prevent cancelation of invoices

    Hi all, We create invoice lists for many customers from the underlying invoices. The invoice lists DO not carry any pricing in them and don't release to acocunting as standard SAP - only the invoices do. Occasionally, due to very high volume of billi

  • XML example for testing query with soapui

    Hello, I am trying to build a query using XML with the downloaded Contact Custom.wsdl. I did get a msg complaining about that there were no session. I've looked into the Web Services.pdf doc and see the description about session, etc. I'd appreciate