Variable problems local and global score

Hi i'm having problem of writing a value to a global variable
in a function and using this variable affterwards. My problems is
the following i have a firstProduct variable that is initialized as
global at the begining of my code and the i have an XML on load
function where i should take the first child and write it to his
variable and use it afterwards for passing it as a variable to PHP
but this is irrelevant, however when im trying to trace im getting
undefined any suggestions ?? here is the code

when i trace the variable inside the function on load it
writes it but when i try to access it outside it is undefined im
really frustrated, how the heck i assing values to variables in
actionscript where i can access them from any frame that i want. do
u have any suggesstions?

Similar Messages

  • Local and global variables in ABAP Debugger

    hi guys.
    we have the following support package:
    SAP_BASIS     640     0025     SAPKB64025     SAP Basiskomponente
    I would like to use in the debugger the local and global variables tab strip, but I can not find it. Is it possible. that our support package is too low for this functionality?
    Thanks a lot.
    rudit
    Edited by: Rudolf Tremmel on Aug 17, 2010 8:35 AM

    Starting with SAP NetWeaver 6.40, SAP released a new version of the Debugger.
    The Debugger available in Release 6.40 was not considered complete (and was
    not the default debugger as a result)
    The Variable Fast Display tool currently has four tabs . The first
    two are provided empty, and you can either type or double click a name in the
    source code to add it to the list. The third tab (Locals) shows all local variables
    for the current program modularization unit, and the fourth (Globals) shows all
    global variables in the current program.

  • How to report with local and global currency in Deliveries?

    Dear all,
    i am working on a delivery scenario where i have in the datasource NETWR(Net value
    ), WAERK (Document currency).
    I would like to be able to report with local currency and global currency.
    Could you please help by explaining how to proceed?
    Thank you.
    Cheers

    Hi Gilo,
    You have to check with the business on the following.
    1) What would be the key date of currency conversion? Is this any document date from the transaction ( Delivery Date ) or report execution date?
    2) What would be the target currency ? ( for local and Global currency ). Whether this can be determined at the time of loading or should it be based on user selection criteria?
    3) What is the exchange rate type that has to be used? ( for example 'M' ).
    Once you have the answers to these questions, you can decide whether to do the currency conversion in the backend or front end in the report during runtime.
    For example, if the user wants to input the target currency on selection variable and wants to use the exchage rate as of the report execution date, then this currency onversion has to be done at runtime.
    For more details,Please check help.sap.com or SDN
    Thanks,
    Krishnan

  • Mix Local and Global Transaction using XA Driver for Oracle

    Hi all,
    We are trying to use a XA Driver which can support both local as well as global
    transaction. We tried using the Weblogic jDriver (XA Driver) type 2 that comes
    along with Weblogic installation but unfortunaltely it cannot mix local as well
    as global transaction.
    Please let me know in case we have any XA JDBC driver for Oracle Database which
    supports both local and global transaction together.
    Thnx,
    Kumar
    Environment:
    Weblogic 8.1 server
    Database used : Oracle8i

    Most database drivers can support local and global transactions, with some
    restrictions.
    The JDBC spec has been changed to require compliant drivers to let the
    application
    know if they try to start a global transaction while a local transaction has
    not been
    completed (or vice verse). So most of the database drivers have been
    changed to enforce
    this restriction (breaking a lot of code that is out there).
    "Kumar Raman" <[email protected]> wrote in message
    news:4033457c$[email protected]..
    >
    Hi all,
    We are trying to use a XA Driver which can support both local as well asglobal
    transaction. We tried using the Weblogic jDriver (XA Driver) type 2 thatcomes
    along with Weblogic installation but unfortunaltely it cannot mix local aswell
    as global transaction.
    Please let me know in case we have any XA JDBC driver for Oracle Databasewhich
    supports both local and global transaction together.
    Thnx,
    Kumar
    Environment:
    Weblogic 8.1 server
    Database used : Oracle8i

  • Local and global POV mode in FDQM

    hi,
    i am using multiload option in fdqm. what is the difference between local and global POV modes in fdqm?
    your help will be highly appreciated.
    Regards
    Ace

    Global Mode: If this mode is set and the POV is changed in FDM, it will change the POV for all users
    Local Mode: if this mode is set and the POV is changed in FDM, it will only change for the current user making the POV change.
    The Mode will change accordingly when using a mulitload file.

  • How to get local and global hostnames working?

    I have a new AirPort TimeCapsule, and I can't get the local hostname (appleair.local) to work from browsers on the local network. Is that how it's supposed to work?
    The TC is in bridge mode because it's behind a Netgear WAP+router -- maybe that is a problem?
    I had to set up a global hostname to get Bonjour working in order to share an old printer (attached to the TC) across the network, but my understanding is that I can't actually use a global hostname from a browser without setting up a dynamic DNS service. Is that right? I'd like to be able to share files and the printer on the TC without using Bonjour if possible.
    Apart from the USB printer attached to the TC, there's an external flash drive attached to the Netgear router used for backups and as a media server.
    I originally configured the TC with my iPhone and an iPad mini, but now I'm working on the advanced settings with a Windows laptop using the Apple AirPort Utility for Windows and connecting to the TC wirelessly. There's a MacBook and iMac that will be added to the network, but they're not available yet so that's why I'm using the PC.

    The 5.6.1 utility for windows is really not up to handling the new AC version TC.. Apple specify that you must use a version 6 airport utility but none has been released for windows.
    You will have to use bonjour for windows. but you should not need to use full domain name..
    By default the TC is local domain. But if your computer is getting an IP from the Netgear it might be in a different domain. How much this matters I am not sure. But I would simply try to get everything on the one domain. I think you are confused anyway.
    I have a new AirPort TimeCapsule, and I can't get the local hostname (appleair.local) to work from browsers on the local network. Is that how it's supposed to work?
    The TC has no html access.. never has had.. probably never will have.. for reasons known only the higher powers of Apple inc.. they do not use standard HTML access.. the only way to access the TC is via airport utility. So putting the ip or the name in a browser is useless.. it will not and cannot respond.
    Sharing printers from the TC to windows is always going to be a mystery bag.. I would suggest you simply delete all your previous attempts and try again.. setting up printers via bonjour in windows.. shudder..
    http://support.apple.com/kb/HT2835

  • Get locals and globals using API

    Hi, I am making in LV an editor for TS. User should be able to change the value of file globals and locals variables. Using TS API, is possible to get all the file globals and locals variables without knowing the name that those variable have in TS? I mean, if I knew the name I could use the Get Property Value with the lookup string. But if the I do not know the name of the variable, can I get the list (and their values) of the variable?
    Thanks a lot.  
    Solved!
    Go to Solution.

    Try the following link
    http://forums.ni.com/ni/board/message?board.id=330&message.id=3390&query.id=6624776#M3390
    In summary:
    Use GetNumSubProperties method to get the total number of Locals / FileGlobals.
    Use GetNthSubProperty to get the sub properties using the an index starting at 0 to GetNumSubProperties-1
    Use the Name property to obtain the Name of the subproperty.
    Regards
    Ray Farmer
    Regards
    Ray Farmer

  • Conflict between local and global step types

    I'm making some changfes in some previous programmed Step Types and I'm having conflicts. Is it posible to make global Step Types? I have some sequences that have another step type with the same name as the global and it appears the Type Conflict Dialog box. I'd like to use in all my sequences always global Step Types. Can I do this with TestStand 2.0.1?

    Hi again,
    For both Step Types A and B, I've inserted an "Edit SubStep" (inside Tab Substeps in the Step Type Properties). Those associated programs are written in LV. That means that when I insert one of my steps types in a sequence, if I click the right bottom, I have the possibility to make changes in this Edit VI and save those parameters in TestStand. I attach you the two Step Types that have the conflict, maybe you can see the problem. Have a nice weekend!
    Angel
    Attachments:
    PXI-6025E_Digital_IO.zip ‏593 KB
    Tilt_Adjustment_Service.zip ‏283 KB

  • Create local or global variables ?!

    hey guys,
    I want to use variables instead of wires , which one you suggest , local or global variables? and why ? 
    thnxxx alot

    blue silver wrote:
    I want to use variables instead of wires , which one you suggest , local or global variables? and why ? 
    In LabVIEW, the wire is the variable.
    Local and global variables have their limited use in certain UI tasks, but lead to inefficient, error prone, and hard to maintain code.
    Local variables create extra data copies in memory, which can be expensive
    They break dataflow and thus lead to race conditions.
    To "fix" the race conditions, you need to clutter your code with sequences.
    ... it's an evil cycle!.
    Why do you think you need local and global variables?
    If you "want" to use them, you are probably misguided. Typically, you should only use them if you "need" to! There are legitimate uses for them.
    LabVIEW Champion . Do more with less code and in less time .

  • Maintain seprately exchange rate for Local transction and Global Transction

    Dear Guru,
    In some countires of Latin america, the local exchange rate ratio between two currencies is differ than the Global exchange
    rate ratio. Is it possible to maitain simultaenously two exchange rate ratio for local and global purpose in sap for day to day
    transction.
    Regards,
    Rajesh

    Nope not possible for day to day real time posting.
    But you can define a non leading ledger and can at period end do th eforeign currency valuation using that specific exchange rate for that non leading ledger.
    Regards,
    SDNer

  • Local attributes - global attributes tradeoff

    Hi, MDM experts.
    Can you, please, share your experience on business partners repository modeling.
    I build custom business partners repository. While creating it I came to a question - whether local system attributes of business partner should be modelled in that repository?
    Intrinsic attributes like Full Name, State Identity Number and so on should be definitely modeled. Attributes specific to our organization but those that span many of our systems should also be modeled I think.
    But what's about some specific attributes that are relevant only for one of the systems being integrated? To be concrete, imagine we have SAP ERP system as one of the systems in landscape and such attribute of our business partner as 'Purchasing organization'. In our case this table is SAP ERP specific and none of our other systems have such entity in their data model.
    <b>The question is - is it reasonable to have local system attributes and lookup tables implemented in central MDM repository?</b>
    If yes then isn't our repository going to be overloaded with all that local attributes and lookup tables of every client system?
    If no, then how should process of central creation of business partner look like? The problem is in this case Creator won't be be able to assign all attributes he would like to and he will have to login to each of local system and assign these values after central creation. Moreover, client systems can refuse to create new record automatically in case some of attributes are missing. For example such situation is typical for Idoc inbound processing .
    Have you any suggestions on streamlining the data model and BP central creation process ?
    Regards,
    Vadim Kalabin

    Hi vadim,
    These are my thoughts on your issue.
    I feel both the attributes should find place in the same repository.
    This is not going to overload the system. In some typical MDM Implementation the volume of Main table records will very huge and the Local and global attributes will only occupy a less share only on the total records.
    Also the practice is that MDM DB Server and the core server runs separately.
    Pl find if this Article is use for you.
    <a href="https://www.sdn.sap.comhttp://www.sdn.sap.comhttp://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/d0d8aa53-b11d-2a10-aca2-ff2bd42a8692">MDM Data modelling do's and dont's</a>
    Regards,
    Vijay

  • Is This a Global Versus Local Variable Problem?

    I intend to use a variable (myselector) with a text value (e.g. roses, Big Sur, Pacific Grove, night, etc.) for the sort criteria of my photography list.  Selection of a tab from a Tabbed Panel will appropriately define the variable and the selected thumbnails will display in the Content Panel.
    The variable "myselector" is defined in the head section; a function for each tab of the Tabbed Panel will redefine the variable per the selected tab.  Within the function, I am not using "var" to call the variable.  Though the variable "myselector" should be global, the changes to its value are discarded when the function closes.  This indicates that it is functioning like a local variable in the function.  After a bit of reading, I've not found the cause of the global/local discrepancy or a fix for it.
    Diagnosis History - I generated a simplified code.  Variable "myselector" is defined as "abcd"; function "myfilter" is called by onclick of the text "button" and changes "myselector" to "efgh".  At the end of the file, I used "document.write (myselector) to output the "myselector" value.  The script follows.
    The end value of "myselector" does not change.  However, when I add "document.write (myselector)" to the function, then the changed value is displayed.
    I ask someone to explain what I am doing incorrectly or, at least, guide me to a solution.  I thank you for your assistance.
    Scott
    <script type="text/javascript">
    var myselector="abcd";
    function MM_callJS(jsStr) { //v2.0
      return eval(jsStr)
    </script>
    </head>
    <body>
    <div id=text>
    <p onclick="MM_callJS('myfilter();')">Button</p>
    <script type="text/javascript">
    function myfilter() {myselector="efgh"; }
    </script>
    <script type="text/javascript">
    document.write (myselector);
    </script>
    </div>

    Dear Ben:
    I thank youfor your patience.  This includes the script using Insert - Syntax Highlighting - Java.
    The coding needs a lot of clean up but I want it to work, first.
    Scott
    <script src="SpryAssets/xpath.js" type="text/javascript"></script>
    <script src="SpryAssets/SpryData.js" type="text/javascript"></script>
    <script src="SpryAssets/SpryTabbedPanels.js" type="text/javascript"></script>
    <script type="text/javascript">
    var dsphotodata = new Spry.Data.XMLDataSet("EM_photo.xml", "/gallery");
    </script>
    <script  type = "text/javascript">
    function MM_callJS(jsStr) { //v2.0
      return eval(jsStr)
    </script>
    <script type="text/javascript">
    var dsphoto = new Spry.Data.XMLDataSet("EM_photo.xml", "/gallery/photos/photo");
    dsphoto.filter(subjectfilter);
    var myselector;
    </script>
    <link href="SpryAssets/SpryTabbedPanels.css" rel="stylesheet" type="text/css" />
    </head>
    <body>
    This is a test of Scott's efforts to program his website.
    <br />
    <br />
    <div id="TabbedPanels1" class="TabbedPanels">
      <ul class="TabbedPanelsTabGroup">
        <li class="TabbedPanelsTab" tabindex="0" onclick="MM_callJS('{myselector=\'animal\'}; subjectfilter(); dsphoto.filter(subjectfilter); ')">Tab 1</li>
        <li class="TabbedPanelsTab" tabindex="0" onfocus="MM_callJS('myselector=\&quot;pgbeach\&quot; subjectfilter(); dsphoto.filter(subjectfilter); ')">Tab 2</li>
        <li class="TabbedPanelsTab" tabindex="0">Blank</li>
    </ul>
      <div class="TabbedPanelsContentGroup">
        <div class="TabbedPanelsContent" >Content 1
          <br />
    <br />
    <script> {document.write (myselector)} </script>
          <br />
          <div spry:region="dsphoto dsphotodata"> <img src="{dsphotodata::thumbnail/@base}{@thumbpath}" width = {@thumbwidth}px height = {@thumbheight}px spry:repeat="dsphoto" onclick="dsphoto.setCurrentRow('{ds_RowID}');" /></div>
        </div>
        <div class="TabbedPanelsContent">Content 2
          <script> {document.write (myselector)} </script>
          <br />
          <div spry:region="dsphoto dsphotodata"> <img src="{dsphotodata::thumbnail/@base}{@thumbpath}" width = {@thumbwidth}px height = {@thumbheight}px spry:repeat="dsphoto" onclick="dsphoto.setCurrentRow('{ds_RowID}');" /></div>
        </div>
        <div class="TabbedPanelsContent">Content 3  <script> {document.write (myselector)} </script><br />
    <div spry:region="dsphoto dsphotodata"> <img src="{dsphotodata::thumbnail/@base}{@thumbpath}" width = {@thumbwidth}px height = {@thumbheight}px spry:repeat="dsphoto" onclick="dsphoto.setCurrentRow('{ds_RowID}');" /></div>
    </div>
    </div>
    </div>
    <div id="Selected_Photo" spry:detailregion = "dsphoto dsphotodata"  >
    <img src="Photo-Thumbnails/{@thumbpath}" width = {@thumbwidth}px height = {@thumbheight}px /><br />
    <img src="Photo-Email/{@path}" width = {@width}px height = {@height}px />
    </div>
    <script type="text/javascript">
    var subjectfilter = function(dataSet, row, rowNumber, criteria) { if (row["@subject"].search (myselector) != -1) return row; return null; };
    <!--
    var TabbedPanels1 = new Spry.Widget.TabbedPanels("TabbedPanels1", {defaultTab:2});
    //-->
    </script>

  • Local variable problem

    I am making an application that takes an apartment number and number of occupants in that apartment and then displays a number of statistics. So far I haven't had much problem
    except on a what is probably a very simple problem.
    I have two buttons, and when "store" is clicked the info in the textboxes is input to an array.
    My problem is with the next button, "quit", this is where all the info is supposed to be displayed.
    All my variables that I need from "store" are local and are recognized in " the if statement in quit. Ive tried declaring them outside of the if statement, but it hasn't been working.
    {code}
    public void actionPerformed(ActionEvent event)
                   Object source = event.getSource();
                   Apartment input;
                   if (source == store)
                        Integer aptNo = Integer.parseInt(input1.getText());
                        Integer occup = Integer.parseInt(input2.getText());
                        input = new Apartment(aptNo, occup);
                        if(aptNo > BUILDING_SIZE)
                             JOptionPane.showMessageDialog(null, "That apartment number doesn't exist.");
                        else if(occup > MAX_OCCUPANTS)
                             JOptionPane.showMessageDialog(null, "Too many occupants, only 20 are permitted per apartment.");
                        else
                             occupants[aptNo] = occup;
                             input1.setText("");
                             input2.setText("");
                             JOptionPane.showMessageDialog(null, input.getNumber(occupants));
                   if (source == quit)
                   // I need the variables aptNo and occup in here to put into my methods for output, but I don't know how to get them.     
    {code}

    EmmCeeVee wrote:
    Thank you for all of the responses, it really helps me out.
    Obviously my knowledge of local variables is hurting as I switched it around as your said and declared the aptNo and occup outside of the if's.
    All I need is for the quit button to look at the array ( which has just been modified by the sotre button) and output a bunch of results.
    Heres where im at:Your problem is of scope of the variables.
    Here whatever variable you defined in actionPerformed they are local for that method (they are out of scope when the method is finished/called again), Upon this, the actionPerformed is called twice one for store and another time for quit. So you cant expect the value stored at store should be there still when you all quit
    If you want those values available on both the actions then make them a class level variables.
    Below is a sample program, might help you.
    class Employee
         String empName = null;
         int empNo;
         Employee(String eName,int eNmbr)
              this.empName = eName;
              this.empNo = eNmbr;
    class CheckVariableScope
            Employee empOb; // Here
         int eNo;
         String eName = null;
         public void checkScope(String action)
                    //Instead of defining Employee reference variable, eNo and eName  in checkScope method, define it @ class level.
                    // in your case they are Apartment input, Integer aptNo and Integer occup
                     // like above i did.
                     // If i comment the class level variable and uncomment method variable, this program also give the same error.
              //Employee empOb;
              //int eNo;             
              //String eName = null;
              if (action.equals("Store") )
                        eNo = 10;
                        eName = "Bob";
                        empOb = new Employee(eName, eNo);
                        System.out.println("The eName is : "+empOb.empName+" , empNo is : "+empOb.empNo);
                   if (action.equals("quit"))
                        System.out.println(" eNO from Object is : "+empOb.empNo);
                        System.out.println(eNo); //Error: may not have been intitialized
         public static void main (String st[])
              CheckVariableScope ob = new CheckVariableScope();
              ob.checkScope("Store");
              ob.checkScope("quit");
    }

  • Shared and Global Variable Issue with Motor VI

    Hello,
    I have written a VI that will command a stepper motor to follow the desired profile and loop the profile until the user pushes the stop button. I modified the state machine example from LV to achieve this. I now want to connect a linear potentiometer to the linear actuator to verify that the distance I commanded the motor to travel is the actual distance that it traveled. I am using a NI 9219 module to collect the data from the potentiometer.
    When I added the potentiometer to the program, the cRIO-9073 chassis that I am using immediately crashes and looses connection with the computer when I click the Run VI button. I looked into this a little more and it seems that the chassis will crash only when I add shared and global variables to the VI. I think it has something to do with the Network Variable Engine; I don’t have it installed on the chassis because the motor program alone will not run if it is installed on the chassis. Also, I have the chassis configured to the RT setting and not the FPGA setting.
    I have attached a snippet of the code. I am using LV 2014 SP1 along with the SoftMotion module. The motor is connected to LV through a P70530 stepper drive which is connected to a NI 9512 module with the proper connectivity bundle. Is there something wrong with the VI that would cause the chassis to crash? Why will the simple motor VI not work when the Network Variable Engine is installed on the chassis? Thank you in advance for your help!

    Follow up to this post:
    Sometimes when I try to connect the project to the chassis I get the following error: "Failed to load shared library taggerrt.out. Ensure that the library is present on the RT target. Use either MAX to install NI software or FTP to transfer custom librarier to the RT target."
    I have tried re-installing the NI Device Drivers and reconfiguring the software on the cRIO chassis using MAX; however, the error keeps showing up. I read somewhere that the taggerrt.out library is a part of the Network Variable Engine but I don't know why it wouldn't be found when the NVE software is installed on the chassis. This message only comes up when I also have the SoftMotion Module software installed on the chassis. Has anybody else encountered this problem or know why this could be happening? Any ideas would be greatly appreciated! Thanks!

  • Urgent : OBIA - Handling multiple Global, Local and Document Currencies

    All,
    I need input on how to configure multiple currency codes in DAC for OBIA 7.9.6.x
    My client's business goes around the the world and with multiple local currencies.They also need reporting currency to be multiple like in Euro, USD etc.
    I went through a couple of threads in this forum,like -
    Re: Configuring Global Currencies in BI Apps 7.9.6 for EBS 11.5.10 Source
    Re: How we are using Global, Local and Document Currencies  in DAC.
    But I have some confusion regarding the configuration of DAC's 3 Global currency codes.
    In order to fulfill my requirement - should I add additional codes in DAC?
    Basically How am I supposed to handle multiple Local,Document and Global currencies? And then possible changes in rpd/reports required also?
    Regards,
    Krish

    Currencies are discussed in the Setup and Configuration Guide here:
    7.1.1.2 How to Configure Global Currencies
    To configure the global currencies you want to report in your warehouse:
    In the DAC Client, display the Design view.
    For more information about logging into the DAC, see Section A.1, "How to Log Into the DAC Client".
    Select a container from the drop down list to the right of the Execute button.
    Display the 'Source System Parameters' tab.
    Locate the following parameters and set the currency code values for them in the 'Value' box:
    $$GLOBAL1_CURR_CODE (for the document currency).
    $$GLOBAL2_CURR_CODE (for the local currency).
    $$GLOBAL3_CURR_CODE (for the global currency).
    Make sure that you spell the currencies as they are spelled in your source OLTP system.
    Save your changes.
    As far as for PLP items, those are Post Load Processing elements that perform cleanup tasks after the Base Warehouse tables have been loaded. They should never be modified and frankly run without any issues provided the rest of the plan executes properly. Do you have a specific quesiton about a PLP?

Maybe you are looking for

  • Why apple id has been disabled?

    Why my apple id has been disabled. .?  How can i enable it?

  • Web layout of jsp report

    Hi All: Please let me know how can i run web layout of jsp report and publish it as portlet? I have successfully deployed my jsp report(web layout),namely my_rpt.jsp, as a J2EE application and when i write URL direlctly in address bar of browser it r

  • There has got to be something wrong with my X230 touchpad

    I just received my X230 in the mail and while overall its a fantastic machine, light, capable, wonderful keyboard, sturdy, the trackpad is absolutely atrocious and I'm not sure if it's supposed to be (since many reviewers have been singing its praise

  • Filesystem check failed SOS!

    hi. I have a problem with my boot. After a sudden power off of my laptop, the filesystem check failed for an unknown reason and the arch brings me up in a terminal (root) session and asks me to check the filesystem manualy and to reboot. I don't know

  • Where has airplay gone?

    cant find it in itunes!!