How to send data to a datagrid, when you click on a line on a label in the other State.

I mean the Datagrid in state1, and state2 label

I try with this code:

protected function listDg_gridClickHandler(event:GridEvent):void

{

If (slistDg.selectedIndex == 0) {}

lblid. Text = "My Text";

currentState = 'State2 ';

}

}

If the label is on the main State it displays the text, but if I use the label in the state2 it gives me an error:

TypeError: Error #1009: cannot access a property or method of a null object reference.

any help?

I have fixed my car, just move the current state to the top and that's all!

protected function listDg_gridClickHandler(event:GridEvent):void

{

currentState = 'State2 ';

If (slistDg.selectedIndex == 0) {}

lblid. Text = "My Text";

It works!

Tags: Flex

Similar Questions

  • When you click on a photo on facebook that loads the new popup, Firefox crashes 10 androgenic. Just Firefox crashes and unresponsive. Is there any solution for this?

    When you click a picture that load the popup that Facebook has recently presented on the occasion of just Firefox crashes and unresponsive and them must be closed using the Manager tasks. It does not occur every time say for every 2 of 10.

    That's what the error report says...

    Description:

     A problem caused this program to stop interacting with Windows.
    

    Signature of the problem:

     Problem Event Name:	AppHangB1
     Application Name:	firefox.exe
     Application Version:	10.0.0.4411
     Application Timestamp:	4f2548ce
     Hang Signature:	4813
     Hang Type:	0
     OS Version:	6.1.7601.2.1.0.256.48
     Locale ID:	2057
     Additional Hang Signature 1:	4813d58d219b01045ae1404b21f04466
     Additional Hang Signature 2:	ec05
     Additional Hang Signature 3:	ec057c79f467a3033cec4ebe11500204
     Additional Hang Signature 4:	4813
     Additional Hang Signature 5:	4813d58d219b01045ae1404b21f04466
     Additional Hang Signature 6:	ec05
     Additional Hang Signature 7:	ec057c79f467a3033cec4ebe11500204
    

    If Firefox crashed, then please provide Crash ID here.

  • Did anyone see a problem when you drag items from first from one monitor to the other with the windows which distort?

    When you drag the window of creative for a monitor to another false windows showing a trail of the toolbars at the bottom of the page. The window does not appear correctly until you press ctrl + alt + del. Anyone have any suggestions on this subject? First Adobe and the GPU driver is up to date. There are no onboard graphics on this computer, only the nvidia gtx 760.

    Downgrading to 340.52 driver solves the problem.

  • How to make a subpage in homepage when you click hyperlink?

    I have a page about, and in this page, I have listed all the Dr. Office.  Now when I select a link I want the selected page opens in the same page.

    Hello

    I think that you are looking for type "Accordion" of affect. If you want to hyperlink elements, it will open the new page, it does not open a subpage in the homepage. Try to use the Accordion widget and see if it serves your purpose.

    Kind regards

    Aish

  • How to make a motion tween play when you click it?

    I am brand new to the FLASh and I have a motion tween of a wheel that rotates 360 degrees and I need to play when it is clicked on.  This is probably something that is really easy to do, but I just can't understand it.  Someone at - it good indications?

    Hello

    you need to do an instance name for your movieclip, for example "myMC". Select the first frame in the new layer, and then click window-> Actions.

    To write:

    myMC.stop (); stop your mc when movie starts

    myMC.addEventListener (MouseEvent.CLICK, regarderMovie); Add a listener for the click of the mouse the mc that will trigger the function playMovie

    playMovie(event:MouseEvent) //function MC function start

    {

    myMC.play ();

    }

    I hope this has been helpful.

  • Open program windows don't close, programs will not open office, when you click on a link to a google search, the search comes up with something totally different

    The problems started only within the past few days.  It's like something has hijacked my computer.  Programs will not open from the desktop but will if I go through the beginning, the road to programs.  Windows open will not close so I shut down the computer.  When I do a search on google and click on the link I want, the computer brings me to something totally different.

    My computer is 5 years and customized with a CORE 2 DUO Intel DG965 motherboard containing:

    INTEL CORE 2 DUO E6300 1.86 GHZ CPU

    2 - DDR2 667 MHZ 512 MB memory modules

    Hello Deb 1948

    There is a great thread about the browser hijacking with links to helpful information in the link below.

    http://answers.Microsoft.com/en-us/Windows/Forum/windows_xp-performance/links-keep-redirecting-me-to-other-websites/4dce5f8c-cf6d-E011-8dfc-68b599b31bf5

    Also download and run Malwarebytes from this link.

    http://www.Malwarebytes.org/

    Fix hijacked browser redirection

    http://www.ehow.com/how_8763774_fix-redirecting-browser-hijacking.html

    Hope it will be useful.

  • How can I make an availability calendar as they use in the touroperater Web sites. A calendar when you click a button, it displays the dates available for booking? Or do I need a database for that?

    I m busy doing a site for a touroperater. I'm trying to figure out how to do an availability calendar. When you click a button, it will display a calendar where you can choose a date where you wish to arrive and when you leave. When you´ve does this, it will show you whether or not your choisen dates are available.

    I hope I have made myself clear with this question.

    Hello

    Take a look at this topic, discussing the same stuff,

    Appointments available for a site of Muse?

    Please let us know if yous until cases of doubt.

  • How to send data in eloqua with using ajax?

    Hello

    someone tell me how to send data using ajax?

    Thank you

    Rahul

    Hi Rahul

    Using this code to send data to AJAX

    $.ajax({)

    URL: ' your action? elqformname = name of the form eloqua & elqSiteID = eloqua site ID',

    type: 'POST',

    data: "field name =" + document.getElementById('field_id').value + "="+ document.getElementById('field_id').value field name,

    success: {function (html)}

    }

    })

    Thank you

    edynamic expert Eloqua

  • How to send data from 150 morethen FlashVars

    Hello

    I need to send the data to flashvars, size is more then 150kb. This data set will be created by javascript.

    Thanks in advance.

    Chavigny

    use a return in your js function to return data to actionscript.

    You can use a timer loop to repeatedly query the js function and check whether the data is available.  When this is the case, put an end to the loop and use the data.

  • How can I get data from each associated XMLnode in movieclips separated when you click a line in the combobox

    How can I get data from each associated XMLnode in movieclips separated when you click a line in the combobox?

    A sample of XML is like this:

    <>planter

    < Lauvtre >

    < Botanisk_navn > Acer campestre < / Botanisk_navn >

    < Norsk_navn > Naverlonn < / Norsk_navn >

    Gronn < Farge > < / fan >

    H4 < Herdighet > < / Herdighet >

    < Hoyde > 10-15 m < / Hoyde >

    < / Lauvtre >

    I have a combobox where it shows the botanical name and the Norwegian name. But the rest of the info in movieclips seem separate.

    Someone has an idea how to do this? Can I use the trace function maybe? Here is my AS3 code so far:

    var loader: URLLoader = new URLLoader();

    loader.addEventListener (Event.COMPLETE, onLoaded);

    list.addEventListener (Event.CHANGE, itemChange);

    function itemChange(e:Event):void

    {

    your. Text = list.selectedItem.data;

    TB. Text = list.selectedItem.label;

    }

    var xml;

    function onLoaded(e:Event):void

    {

    XML = new XML (e.target.data);

    var it: XMLList = xml. Planter.Lauvtre;

    for (var i: uint = 0; i < il.length (); i ++)

    {

    list.addItem ({data: it.}) Farge.Text ([i]) + "\n"+ it.» Herdighet.Text ([i]) + "\n" + it. Hoyde.text ([i]),

    label: it. Botanisk_navn. Text() [i] + "\n"+ it.» Norsk_navn. Text() [i]});

    }

    }

    Loader.Load (new URLRequest ("lauvtre.xml"));

    Thank you!

    Rheus.

    I don't know what you're trying to do.  but, if you want to fill one combobox with the botanical names and when one is chosen, the other use of logins:

    var loader: URLLoader = new URLLoader();

    loader.addEventListener (Event.COMPLETE, onLoaded);

    list.addEventListener (Event.CHANGE, itemChange);

    function itemChange(e:Event):void {}

    var selectedObj:Object = a [list.selectedIndex]

    trace (selectedObj ['fan'], selectedObj ['Botanisk'], etc);

    }

    var xml;

    var a: Array = [];

    function onLoaded(e:Event):void {}

    XML = new XML (e.target.data);

    var it: XMLList = xml. Lauvtre;

    for (var i: uint = 0; i

    list.addItem({label:il[i].child('Botanisk_navn').toString()});)

    a [i] = {'Fan': it [i].child('Farge').toString (), 'Herdighet': it [i].child('Herdighet').toString (), "Hoyde": he [i].child('Hoyde').toString (), 'Botanisk':il[i].child('Botanisk_navn').toString(),'Norsk_navn':il[i].child('Norsk_navn').toString()};}

    }

    }

    Loader.Load (new URLRequest ("test.xml"));

  • How to set a default in an ADF table when you add a new line

    Hi guys,.

    I have a view object which I use to create a table of the ADF. I also have a button that uses a CreateInsert link to add a new row to the table. I have four fields: created_by, creation_date, last_update_by and last_update_date.

    I want these values to be set automatically when I click on add new rank.

    I want the following values:

    created_by - admin
    CREATION_DATE - sysdate
    last_update_by - admin
    lsat_update_date - sysdate

    Any suggestions on how to proceed would be appreciated

    Thank you
    -Mark

    brand,

    These four fields can be defined completely declaratively in the Entity object (check the service history Colum). Copied from (11 g) documentation:

    If you want to keep track of the historical in your entity object information, such as when an entity has been created or changed and by whom, or the number of times that the entity has been modified, you specify an attribute with the selection of historic column (in the Edit attribute dialog box).

    If an attribute data type is number, string or Date, and is not part of the primary key, you can then enable this property for your entity automatically update the attribute for the audit of historical value. How the framework handles the attribute depends on the kind of historical attribute, you specify:

    * Created the: this attribute is populated with the timestamp of when the line was created. The time stamp is obtained from the database.
    * Created by: the attribute is populated with the name of the user who created the line. The username is obtained using the method getUserPrincipalName() on the Session object.
    * Modified the: this attribute is populated with the time stamp whenever the row is updated / created.
    * Update by: this attribute is populated with the name of the user who creates or updates the row.
    * Version number: this attribute is filled with a long value that is incremented whenever a row is created or modified.

    John

  • How to open 2 sites on start and 1 Web site when you click the home button?

    How to open 2 sites on start and 1 Web site when you click the home button?

    You can change your shortcut on the desktop Firefox with two starting URLS. To try:

    • Shortcut on the desktop: right-click on the icon, choose Properties
    • Icon taskbar pinned: clic click right on the icon, right click in Mozilla Firefox, click on properties

    Windows normally selects the shortcut tab. If this is not the case, go ahead and click on the shortcut tab.

    You will see the target highlighted. On 64-bit Windows, which is usually either not less the following:

    "C:\Program Files (x86)\Mozilla Firefox\firefox.exe"
    

    For the specific shortcut launch pages, you can add them to the end, for example:

    "C:\Program Files (x86)\Mozilla Firefox\firefox.exe" -url "http://www.dilbert.com/" -url "http://www.gocomics.com/pearlsbeforeswine"

    After OK'ing the Properties dialog box, you can test everything right now to confirm that Firefox is now launching a window with tabs. Either:

    • Double-click the shortcut on the desktop
    • right click on taskbar icon pinned, click Mozilla Firefox

    Who do you want?

  • When you click on a tab open, how to do the update automatically in the body of the page?

    When you click on a tab open, how to do the update automatically in the body of the page?

    Right clicking on a tab open and using the arrow keys now now moves through open tabs. I liked the old versions where just after having clicked on a tab you can directly go to the page with the arrow keys to navigate.
    Y at - it something that I can change the subject: config to change this behavior?
    Thanks in advance.

    Firefox has yet to set the focus in the area of browser if you click on a tab.

    Only with very old browser versions you could set the focus to a tab by clicking a tab.

    This problem is probably caused by an extension.

    Start Firefox in Safe Mode to check if one of the extensions (Firefox/tools > Modules > Extensions) or if hardware acceleration is the cause of the problem (switch to the DEFAULT theme: Firefox/tools > Modules > appearance).

    • Do NOT click on the reset button on the start safe mode window or make changes.
  • When you visit a particular site my user name is entered automatically when you click in the required area. I want to avoid this, how?

    This site requires a username to be filled in a specific area and in another box, you enter a series of numbers generated by a generator of numbers (so not a password - different series each time that you open a session).
    However I do not want my user name appears automatically in the first box. Trying to change that in the security settings (extra-options-security), there is a password section where you can choose any exceptions to the rule of the memory (if the box remember is marked). When clicking the exceptions button, the url of the site I'm talking about is not displayed, and it cannot be entered either, since you can't delete here.
    When you click on the option "saved passwords", nor the site, nor the username is listed. I think I've read all the help sections regarding usernames and passwords, but found no solution.
    How can I avoid this username (so only a user name - not the usename/password combination), appear in the box?

    Click on the box, hover over the drop-down menu with your mouse, if you select the word you want to delete, and then press the delete key. If Firefox fills automatically in forms of control

  • How can I get a light flashes when you receive calls if you can call silence please

    How can I get a light flashes when you receive calls if you can call silence please

    Hello Linda08,

    Go to setting/general/accessibility, walk down for hearing and toggle "Flash LED for alerts"

Maybe you are looking for