refresh the component whenever it becomes visible

This is probably not the first time at his request, but search results are not much of a help.

in the Main.mxml that I have two buttons to display (or hide) of custom components.

the first time that the components are loaded / showed that they use the creationComplete event with lets call the init() method. (a call of service/CallResponder to fill some signs/labels etc.)

When switching to and on components likely to have changed the information contained in the database and for this purpose, I need to remind the init() method again to restart the service/CallResponder again. So, I always have the info displayed on my screen most acurate.

is it possible to invoke the init() method whenever the custom component becomes visible?

Thanks in advance

Arjan

static cooling, follow these steps:

public static void refresh(event:Event):void {}

event.currentTarget.init ();
}

This will ensure that init is called on the particular instance with distributed event.  Also your init function now takes a parameter of the event, you must be making it optional or remove it completely.

I just put an alert and trace in the updating of the static function "empty."

good event that her name in the show, it is never triggered?

How do you get the visible component?

Tags: Flex

Similar Questions

  • Refresh the component Data?

    Hi all

    In one of the States ("HotelUserState") of my application, I have a (HotelList) component within a component (HotelUser). The idea is that the user can choose what Hotel he wants to add/remove/mod users using the component HotelList and once chosen it sends an event to HotelUser so it can change a State to view a list of the user.

    The problem is that if I navigate away once I chose a user and then come in this State... I'll still see the last screen, the component will not display data, as the data is not updated (for example if I create a new hotel...).  I would like it to start from scratch every time, but I can't seem to get it. I know enterState

    This is how in my main application state called when selected in a menu bar:

    < name mx: State = "HotelUserState" >
    < mx:AddChild position = "lastChild" >
    < ns1:HotelUser = "53" x y = "72" >
    < / ns1:HotelUser >
    < / mx:AddChild >
    < / mx: State >

    Then my HotelUser component looks like this (Simplified):

    " < = xmlns:mx mx:Canvas ' http://www.Adobe.com/2006/MXML "width = '710' height = '502' xmlns:ns1 ="components.*"> "
    < ns1:HotelList id = "hotelList" horizontalCenter = "0" red "-21" = >
    < / ns1:HotelList >

    < / mx:Canvas >

    In short, how can I have the component HotelList refreshed/recreated this time, it appears so it pulls these latest news? I know it must be something really Basic... but I can't seem to be able to do.

    Tips are welcome! Thank you!

    Alex

    Hello

    Re-create the component - not a good idea.

    It is better to use it as a dataRenderer.

    Your HotelList must have something like or data dataProvider property. So by changing internal data should change.

  • Load the image when she becomes visible?

    I have a number of itemrenderers in a list that contains images. I would like to only load the image that belong to the visible itemrenderers.

    I thought I saw this fact in another mobile flex projects, but I don't know how to do it.

    Does anyone know how to do this? It is built based on flex?

    See the documentation for the Image of the spark. It has an image caching features.

    http://help.Adobe.com/en_US/Flex/using/WSc5cd04c102ae3e97-33ad5caa12c719dc7c8-8000.html#ws c5cd04c102ae3e97-33ad5caa12c719dc7c8-7ffc

    In addition, by default, sets useVirtualLayout list = 'true '. This means that only the visible rendering engines will actually created.

  • How to put the component to BPC become a form of circle

    How instead of the item display as the image below? I'm trying to go to ultiboard. Thanks for help

    Hi Marxurs,

    Ultiboard, there is an option to display angle curves all and this is useful when you work on a point in polar coordinates.  Select Options > customize the User Interface, on the 'Orders' tab select 'Place' in the 'Catégories' window, then select "place the Angle line (Place) ' under the 'Orders' box, hold down the left mouse and drag this option and drop it somewhere on your toolbar to place an icon.  If you prefer, instead of placing an icon in your toolbar, you can create a keyboard shortcut.  Select the "Keyboard" tab in the Customize dialog box, and then locate the place all the lines of the angle and assign the keyboard shortcut for this option.

  • How to fill the empty space when the component is not visible or hidden?

    I have several components in BorderPane which can be visible or not using not check box. When I put the component not to be visible, I get an empty space I want to complete resizing the next component. What options are available to configure the components to fill the empty space when the component is defined on .setVisible(false); ?

    So that a node only takes place when it is invisible,

    before you change the visibility property, call:

    node.managedProperty().bind(node.visibileProperty());
    

    Or you can simply remove the node from the graphic scene:

    parent.getChildren().remove(node);
    
  • I can't find the FF in 10 Windows anywhere... I downloaded, refreshed, etc... but no visible icon on the desktop, the icon taskbar, dosen't show at "all apps".

    I can't find the FF in 10 Windows anywhere... I downloaded, refreshed, etc... but no visible icon on the desktop, the icon taskbar, dosen't show at "all apps".

    See if there is a Mozilla Firefox directory in C:\Program Files (x 86). If so and there are files in this directory, you should be able to reinstall Firefox without losing your preferences.

    Also, you should be able to run it by typing "Firefox" at a DOS command prompt. If it is running, then just create icons yourself.

  • Netflix continues to become out of sync and I continue to have refresh the page

    I continue to have refresh the page then I watch netflix because it comes out of cynic.i have uninstalled and reinstalled silver lite.i contacted netflix about the problem.they say its Microsoft Works does not

    Original title: Netflix continues to become off synic

    Hello

    1. what operating system is installed on the computer?

    2. What is the exact error related to out of sync?

    3. were there any changes (hardware or software) to the computer before the show?

    Method 1: Run the troubleshooter, if Windows 7 is installed on the computer.

    Open the troubleshooting of Audio playback

    Method 2: To update the display drivers and check.

    Updated a hardware driver that is not working properly

    Update a hardware driver that is not working properly (Windows Vista)

    How to manage devices in Windows XP

    Hope this information helps.

  • Refresh the page when visibility regained

    I run my app calendar to allow the user to create a new appointment. I do this by using the InvokationManager page and the Page is in turn inside a NavigationPane. I would like to refresh the content of the page when the user closes the application calendar and visibility gains my app page.

    Is it possible to do? I looked for a signal of visibility in the Page class but cannot find anything relatively to the change of visibility.

    The only way to do it with the invocation is if you call them a card.

    You can then hang in to the cardDoneMessage...

    http://developer.BlackBerry.com/native/reference/Cascades/bb__system__carddonemessage.html

  • Have the drop-down list boxes become visible depending on the selection in a previous drop-down list box?

    Hi, im doing a form that only shows some options based on the previous selections.

    So far I have buttons which allow a user to select a specific product, and then by using the drop-down combo boxes select some optional features.

    I then have a simple javascript code that bears the name of a product at a price (i.e. the user selects product 'A', the review sections shows priced at $ 99).

    My problem is with additional customization options that depend on previous choices.

    Is it possible to have some drop-down list boxes become visible depending on the selection in a previous drop-down list box? If yes how could I impliment it?

    Currently my best idea is to have a button that could ask the user if he or she had previously chosen a certain selection and then reveal areas of correct drop-down list accordingly.

    Thank you

    Hello

    With a small change I think that the code works as expected. I changed your mainDD.value to event.value, as on the validate event the mainDD.value property cannot be updated as expected.

    script

    this.getField("Dropdown2").display = display.hidden;

    this.getField("Dropdown3").display = display.hidden;

    this.getField("Dropdown4").display = display.hidden;

    Switch (event.value)

    {

    case "a":

    this.getField("Dropdown2").display = display.visible;

    break;

    case "b":

    this.getField("Dropdown3").display = display.visible;

    break;

    case 'c ':

    this.getField("Dropdown4").display = display.visible;

    break;

    by default:

    break;

    }

    end of script

    Hope this helps

    Malcolm

  • Can someone tell me if there is a way that I can put a webpage to load a new image whenever a visitor refreshes the page?

    I pray that I can find a way to do it without losing my mind/writing and troubleshooting of javascript. I would like to have three images per page main Department on the below website link, but I don't want to show them all at once. I want a new image is displayed whenever a visitor visits or refreshes the page. Does anyone have any idea if I can do this in Dreamweaver and how? Please help if you can.

    Here is the link: http://www.graphicmechanic.com/DEKALBCOUNTY/parks-and-recreation/index.html

    See the words in large print 'Parks and Recreation '. My goal is to have the next clown/face paint picture of him change, to something else, every time it loads. I would like to know if my explanation is confusing if you please.

    Please do a search on the Forum for 'random image '.

    You will find previous discussions of 200 +.

  • Problem with the pdf export: text box becomes visible

    When I export to pdf format, sometimes a text box lines become visible. In Indesign, I put them in transparent, so you don't see them here. But after an export to PDF, they are visible in the form of thin white lines. I tried to export to EPS and also here it gives white lines: the borders of a text box. Seems not all the text boxes. But sometimes one or two.

    So let me assure you... it will DESTROY the quality.

    Bob

  • Refresh the page after the fires of fileDownloadActionListener

    Hello experts!

    I use jDeveloper 11.1.1.7.0

    I have a table in a fragment of page jsfff with a button to upload the files that are shown in this table. After downloading the files, I need update the table.

    Downloading files when the user presses the button (partialsubmit = false) I invoke another button hidden (partialsubmit = false) which has af:fileDownloadActionListener that performs the action. (This is because I am doing other activities before you download files)

    It works fine, but I need to refresh the page (among others) after downloading the files. How can I do this?

    I tried to update the table of

    -method fileDownloadActionListener

    -Method of hidden commandButton action

    -The partial trigger table button

    But I could not update the table with any of these

    How can I refresh the table after uploading the files?

    Yes.

    I'm looking at the source code for FileDownloadActionListener.processAction ().

    After invoking the method property, he calls FacesContext.responseComplete (); which ignores the render response phase.

    And so you can not rynefall page at all.

    An in-depth, that you can do, is to use af:poll, IE, activate the survey by clicking on the button visible (in javaScript)

    Here you can see how to start the survey by javaScript:

    GEBS | Oracle Fusion Middleware 11g ADF progress indicator

    (search handlePoll )

    In the pollListener, you can refresh the page AND also disable survey by itself (by calling setInterval(-1))

    After questioning to stop, you must refresh the survey component, with

    AdfFacesContext.getCurrentInstance (.addPartialTarget(...your_poll...whatever));

  • As for access to the id of the component in the element of the action script converter

    Hello

    I enclose the screenshot and the code snippet, as a result of the screenshot, I explain my problem.

    input_image.JPG

    Here you can see two panels with the same data, but each Panel is to have his own dataprovider. I used for combobox itemRenderer. When the type of the parameter 'Date' is selected in one of the row of each Panel, then at that time date combobox must become visible, as I'll have different date formats in the comboxbox. I used the outerDocument to call the method in the actionscript code, but I cannot access the id of the combobox of date format. As I rolled alert to check is I am able to call the method, tht works very well. Please help me how to control the visibility(visible=true/visible=false) of the list box dropdown date format on the choice of date in the parameter type combo box. Also, I paste the snippet of code here...

    < mx:Script >
    <! [CDATA]
    Import mx.controls.Alert;
    Import mx.controls.ComboBox;
    Import mx.events.CloseEvent;
    TO check the status on ComboBox
    public void closeHandler(event:Event):void {}
    Alert.Show ('Hello');
    If (SelectedIndex of the ComboBox (event.target) == 1)
    Alert.Show ('parentApplication.paramType')

    inputGrid.paramType.visible = true;
    parentApplication.comboD.visible = true;
    on the other
    parentApplication.comboD.visible = false;
    }
    []] >
    < / mx:Script >
    < mx:XMLList id = 'service' xmlns = "" >
    < parameter >
    < parameterName > Param - 1 < / parameterName >
    < comboSlctIdx > 0 < / comboSlctIdx >
    < validSlctIdx > 0 < / validSlctIdx >

    < / parameter >

    < parameter >
    < parameterName > Param - 2 < / parameterName >
    < comboSlctIdx > 0 < / comboSlctIdx >
    < validSlctIdx > 0 < / validSlctIdx >
    < dtSlctIdx > 0 < / dtSlctIdx >

    < / parameter >
    < / mx:XMLList >
    < mx:XMLList id = "comboDS" xmlns = "" >
    < parameter >
    < label > String < / label >
    < data > true < / data >
    < / parameter >
    < parameter >
    < label > Date < / label >
    < data > true < / data >
    < / parameter >
    < parameter >
    < label > Integer < / label >
    < data > true < / data >
    < / parameter >
    < / mx:XMLList >

    < mx:XMLList id = "comboV" xmlns = "" >
    < parameter >
    < label > required < / label >
    < data > true < / data >
    < / parameter >
    < parameter >
    < label > not required < / label >
    < data > true < / data >
    < / parameter >

    < / mx:XMLList >

    < mx:XMLList id = "comboD" xmlns = "" >
    < parameter >
    < label > JJ/MM/AAAA < / label >
    < data > true < / data >
    < / parameter >
    < parameter >
    < label > JJ/MM/AAAA < / label >
    < data > true < / data >
    < / parameter >
    < parameter >
    < label > AAAA/MM/JJ < / label >
    < data > true < / data >
    < / parameter >
    < / mx:XMLList >

    < mx:XMLList id = "service1" xmlns = "" >
    < parameter >
    < parameterName > Param - 1 < / parameterName >
    < comboSlctIdx > 0 < / comboSlctIdx >
    < validSlctIdx > 0 < / validSlctIdx >
    < / parameter >

    < parameter >
    < parameterName > Param - 2 < / parameterName >
    < comboSlctIdx > 0 < / comboSlctIdx >
    < validSlctIdx > 0 < / validSlctIdx >
    < dtSlctIdx > 0 < / dtSlctIdx >
    < / parameter >
    < / mx:XMLList >

    < mx:XMLList id = "comboDS1" xmlns = "" >
    < parameter >
    < label > String < / label >
    < data > true < / data >
    < / parameter >
    < parameter >
    < label > Date < / label >
    < data > true < / data >
    < / parameter >
    < parameter >
    < label > Integer < / label >
    < data > true < / data >
    < / parameter >
    < / mx:XMLList >

    < mx:XMLList id = "comboV1" xmlns = "" >
    < parameter >
    < label > required < / label >
    < data > true < / data >
    < / parameter >
    < parameter >
    < label > not required < / label >
    < data > true < / data >
    < / parameter >

    < / mx:XMLList >

    < mx:XMLList id = "comboD1" xmlns = "" >
    < parameter >
    < label > JJ/MM/AAAA < / label >
    < data > true < / data >
    < / parameter >
    < parameter >
    < label > JJ/MM/AAAA < / label >
    < data > true < / data >
    < / parameter >
    < parameter >
    < label > AAAA/MM/JJ < / label >
    < data > true < / data >
    < / parameter >
    < / mx:XMLList >

    < mx:DataGrid id = "inputGrid" width = "100%" dataProvider = "{services}" >
    < mx:columns >
    < mx:DataGridColumn headerText = "Parameter name" dataField = "parameterName" fontFamily = "Arial" letterSpacing = "1" textAlign = "center" / >
    < mx:DataGridColumn headerText = "Parameter Type" fontFamily = "Arial" letterSpacing = "1" textAlign = "center" >
    < mx:itemRenderer >
    < mx:Component >
    < mx:HBox horizontalAlign = "center" >

    < mx:ComboBox id = dataProvider = "{parentApplication.comboDS"paramType"}" selectedIndex = "{data.comboSlctIdx}"close = "outerDocument.closeHandler (event);" / >

    < / mx:HBox >
    < / mx:Component >
    < / mx:itemRenderer >
    < / mx:DataGridColumn >

    < mx:DataGridColumn headerText = "Validation" fontFamily = "Arial" letterSpacing = "1" textAlign = "center" >
    < mx:itemRenderer >
    < mx:Component >
    < mx:HBox horizontalAlign = "center" >
    < mx:ComboBox dataProvider = "{parentApplication.comboV}" selectedIndex = "{data.validSlctIdx}" / > "
    < / mx:HBox >

    < / mx:Component >
    < / mx:itemRenderer >
    < / mx:DataGridColumn >
    < mx:DataGridColumn headerText = "" >
    < mx:itemRenderer >
    < mx:Component >
    < mx:HBox horizontalAlign = "center" >
    "< mx:ComboBox id = dataProvider =" {parentApplication.comboD "dtType"} "selectedIndex =" {data.dtSlctIdx} "visible ="false"/ >
    < / mx:HBox >

    < / mx:Component >
    < / mx:itemRenderer >
    < / mx:DataGridColumn >

    < / mx:columns >
    < / mx:DataGrid >

    Thanxs

    Gerard

    follow these steps:

    -the change of Manager from the drop-down list type, change a property of the row (data)

    change = "{Data .selectedParamType = paramType.SelectedItem.Label.ToString () ;} ', for

    -Change the visible property of the combo of date:

    visible = "{Data .selectedParamType =='Date ' '} ', for"

  • Firefox 4 beta 11 automatically refreshes the hotmail every 1 to 2 seconds, its so annoying when reading emails

    whenever I opened my Hotmail Inbox and try to read an email, Firefox keeps on self-identity, and I can't read my emails or check anything because it's just warn on refresh the page itself, I noticed this problem only with my hot mail when my Hotmail account is connected.

    This is a known bug and Microsoft are working on a fix. They intend to fix this before Firefox 4 release candidate phase stretches.

    One solution is to change a preference in Firefox:

    1. Type of topic: config in the address bar and press on enter
    2. Accept the warning message that appears, you will be taken to a list of preferences
    3. Search the html5.enable preference and double-click it to change its value false

    If you do, don't forget to set back to true preferences by double-clicking it, once again when Firefox 4 release candidate is available, the bug should be resolved by then.

  • [SOLVED] What mechanisms could cease my audio plug-ins (dll) to refresh the view in response to the actions of the mouse

    Hello.

    I have a Digital Audio Workstation (DAW) app. It uses 3rd party secondary applications to provide instruments and sound effects. They are called audio plugins. They are essentially the DLLs that contain the effect/instrument (applet) or provides the shell she. Applets are of two kinds. DXi and VST.

    When I run one of these cmdlets in any kind, they usually provide a Visual for the first actions a mouse or two response (for example by pressing a button or if you turn a knob) but then refresh the applet screen freezes. The mouse actions are still being processed - I can here the changes, but the screen of the applet is not updating. If I close the applet and then open it again, the changes previously not displayed are now visible.

    There is the ability to run some of these cmdlets in the so-called autonomous mode, where a small .exe file is used to invoke/host of the dll. The cmdlets that have this, work very well in this mode. The other windows in the DAW work very well.

    To begin to address this problem, I need to understand the mechanisms under Windows XP Pro 32-bit (fully updated and .net4) by which an applet would have its screen updated. I guess that there is a call system with a description and a chain of connections that has to happen for that to happen or stop.

    Or if you just know how to solve this problem (no one seems so far) the answer would be even more useful.

    Best regards & thanks,

    SJ

    Hi plectrum.

    It was Windows services. I'm not sure the RAM being blocked even though my machine is light enough. There are only a small number of applications audio and all windows XP management services have been used. The advantage of the Sonar, it is quite complete. I just used it and freebies from Native instruments.

    This problem is something that has occurred at some point in the last six months, less than 8.5 and before the free NOR, when I remember vaguely a document with sessiondrummer at this time. It's just something I "necessary" to notice since X 1 has been on a couple of weeks. The actual sonar projects seem to go better under X 1 than 8.5. The behavior of the machine in general gives the indication of any permutation of excessive page to compensate for the blockage RAM.

    Having said that, I recognize and approve your excessive services point will seize resources RAM and which can lead to a particular behavior - which it certainly was. However, unless I take the time to find the offending boot service and reproduce the fault I am not able to confirm that the cause was RAM clogging.

    Kind regards

    SJ

Maybe you are looking for