display a viewstack based on the selected item in a datagrid control

Hello

I am bit new to bending even though I have been using CF for a while but could do with what I hope, it's a simple answer to a simple question...

I have a datagrid that displays a number of columns that a 'typical' I want to be able to display a viewstack child is based on the "type" selected in the data grid. I tried a number of ways that fail, annoyingly.

the latest incarnation of the code is as follows

part of script function

private void dataGridChangeHandler(event:Event):void
{
Get the line datagrid selected item
var Type: String = event.target.selectedIndex;

Set the index of view stack
this.pagesStack.id = Type;
}

<! - part datagrid - >

< mx:DataGrid id = "EpisodeDatagrid" selectable = "true" = "true" Exchange draggableColumns = "this.dataGridChangeHandler" variableRowHeight = "true" editable = "false" height = "100%" textAlign = "center" width = "100%" > "
< mx:columns >
< mx:DataGridColumn id = "startdate" dataField = "EpisodeStartdate" headerText = "Start Date" labelFunction = "dateLabelFunction" headerWordWrap = "true" / >
< mx:DataGridColumn id = "enddate" dataField = "EpisodeEnddate" headerText = "End Date" labelFunction = "dateLabelFunction" headerWordWrap = "true" / >
< mx:DataGridColumn id = dataField 'Type' = "Episodetype" headerText = "Type" headerWordWrap = "true" / >
< mx:DataGridColumn id = "Status" dataField = "EpisodeStatus" headerText = "Status" headerWordWrap = "true" itemRenderer = "active" / >

< / mx:columns >

< / mx:DataGrid >

<!-Viewstack part->

< mx:HBox width = '100 percent"height ="100% ">

< mx:ViewStack id = "pagesStack" width = "555" height = "202" >

< mx:Canvas id = "DIP" label = "DIP" >
< mx:Panel x = "10" y = "10" width = "250" height = "200" layout = "absolute" >

< mx:Label = "19" x = "51" text = "DIP" / >
< / mx:Panel >
< / mx:Canvas >

< mx:Canvas id = "ERASER" label = "ERASER" width = "100 percent" height = "100%" >
< mx:Label = "19" x = "51" text = "ERASER" / >
< / mx:Canvas >

< / mx:ViewStack >

< / mx:HBox >

help would be very appreciated (code example would be more appreciated :)



     
          
     
     
     
          
               
          
          
               
          
          
               
          
     


Tags: Flex

Similar Questions

  • To access the selected items in a ListBox control

    In LabVIEW 2010, I have a ListBox control. How can I get a list of the objects that the user selected in the ListBox?

    I don't see any method, property or event that would provide this information.

    Thank you.

    The value of the ListBox are the indexes of the selected items.

    If you allow the user to select "0 or more' items, the data type will change in a table."

    To get the names of the selected items (I guess that is what you want), you should India property 'element names.

    Tone

  • How to replace the selected item in a tree control?

    How to replace a selected item in a tree control by a new order of string?

    Next time, try to be more specific.

  • COMBOX Box not displaying the selected item

    Here is the code I use to try to capture and display the selected item in a ComboBox control:

    private void changeProjectTypeSelection(event:Event):void {}
    projectTypeChange.text += event.currentTarget.selectedItem.cboProjectType + "" +.
    event.currentTarget.selectedIndex + "\n";
    }


    Then the ComboBox:
    < mx:ComboBox fontSize = "12" x = "93" y = "83" width = "110" id = "cboProjectType" dataProvider = "{projectTypeArray}" labelField = "projectTypeName" selectedIndex = "0" click = "changeProjectTypeSelection (event)" > < / mx:ComboBox >

    Then the TextInput:
    < mx:TextInput id = "projectTypeChange" "248,95" = x y = "84" width = "121" / >

    I know there is something wrong with ActionScript... just have not thought of it. Any suggestions would be greatly appreciated!

    Finally! Here is the solution:

    private void changeProjectTypeSelection(event:Event):void {}
    var i: int;
    for (i = 0; i<>
    If (projectTypeArray.getItemAt (i) .projectTypeName == event.currentTarget.selectedItem.projectTypeName) {}
    projectTypeChange.text = projectTypeArray.getItemAt (i) .projectTypeName;
    }
    }
    }

  • Outline around the selected items of OCD

    WebHelp. RH9

    I just installed IE9 and when I run my published WebHelp and select a link in the table of contents, it displays an image dotted around the selected item. This never happened with IE8, so I was wondering if there is anyway to prevent it? Is it possible to add a "outline: no ' somewhere in the RoboHelp output (as you would in styling a CSS link) so that it does not appear?

    Thank you very much

    Jonathan

    Hi Jonathan,.

    Unfortunately, IE was a nut that is more difficult to crack than I imagined. The problem is that IE9 supports the css schema, but the table of contents is running in mode of whims so no goodness IE9 it... There is a solution, it's just not as easy as I thought. See http://www.wvanweelden.eu/robohelp/modifying_webhelp/remove_outline_in_toc for a step by step guide to get rid of the sketch.

    Note: If you let me, I would use your example on my site image. It seems much better than the image for example, I added

    Take a bow

    Willam

  • Fill a combobox based on the selection of another

    Hi all

    I have a combobox that is filled dynamically. I want to fill an another combox based on the selected item in the combobox first. I use PHP to manage the connection to the database. The drop-down list box cbDivision fills very well.

    Can someone point me in the right direction?

    Here is my code:
    [Bindable]
    public var selectedItem:Object;

    [Bindable]
    private var datalist: ArrayCollection collection;
    private void resultHandler(event:ResultEvent):void {}
    DataList = event.result.data.row;
    }
    [Bindable]
    private var datalist2:ArrayCollection;
    private void resultHandler2(event:ResultEvent):void {}
    Datalist2 = event.result.data.row;
    }

    "" < mx:HTTPService url = " http://127.0.0.1/getDivisions.php"
    ID = "xmlGetDivisions".
    showBusyCursor = "true".
    result = "resultHandler (Event)" "
    method = 'GET' / >

    "" < mx:HTTPService url = " http://127.0.0.1/getFacilities.php"
    ID = "xmlGetFacilities".
    showBusyCursor = "true".
    result = "resultHandler2 (Event)" "
    method = "POST" >
    < mx:request xmlns = "" >
    < DivisionValue >
    {selectedItem.Division}
    < / DivisionValue >
    < / mx:request >
    < / mx:HTTPService >

    "< mx:ComboBox ="116"x ="60"id ="cbDivision"editable ="false"active = 'true' prompt = 'Please select' close ="selectedItem = ComboBox (event.target) .selectedItem, xmlGetFacilities.send ();"initialize =" getDivisions () "dataProvider ="{datalist}"= 'Division' labelField >
    < / mx:ComboBox >

    < mx:ComboBox = "413" x = "60" id = "cbFacility" editable = "false" enabled = "true" initialize = "xmlGetFacilities.send (); ' prompt = "Please sΘlectionner" dataProvider = "{datalist2}" labelField = "Name" > < / mx:ComboBox >


    Thank you in advance!

    No need to answer. I have it working now. It turns out that it was a problem with my PHP code.

  • Dynamic action - set a value of element based on the selection of lines of report

    Hi people,

    Does anyone have an example how to set up a dynamic action, which could fill an element with the selected ID based on the selection of line of the report on the same page?

    Demo:
    http://Apex.Oracle.com/pls/Apex/f?p=19543:2

    If I select an item in the report, then I would fill in 'Selected ID' element with the value of the selected report EMPNO line.


    Later, I would use it for the display of parts of master / detail on the same page.

    Thank you very much
    Tomas

    For this sample page, add the following JS code to run when the page is loaded.

    $('.highlight-row td').click( function(){
      //fetch record id from the cell contents of first column in row
      id = $(this).parent().children('td:eq(0)').text();
      //set page item to selected id
      $('#P2_SELECTED_ROW').val(id);
    });
    
  • Retain the selected items on the right side of the shuttle in cascade

    Hello

    I'm under Apex 4.0.2 and have a cascading shuttle point so that a user can filter the left side of the shuttle using the text field.

    However when filter it - the shuttle seems to lose the items already selected on the right side.

    How can I change the element of the shuttle so that the user can always see the selected items, and the filter only works the unselected points (left side)?

    Thank you
    Keith

    Hi Keith,

    I don't have a blog, so there is no post. However, this is what I did:

    1 set the P298_FILTER element to 'Submit when you press enter' and added a branch to the page that redirected to the same page

    2. make the following settings for the P298_SHUTTLE element:

    Cascading LOV Parent article (s): P298_FILTER
    Page items to submit: P298_SHUTTLE
    List of values definition:

    SELECT ENAME d, EMPNO r
    FROM EMP
    WHERE UPPER(ENAME) LIKE UPPER(:P298_FILTER) || '%'
    OR '%' || :P298_SHUTTLE || '%' LIKE '%:' || EMPNO || ':%'
    ORDER BY UPPER(ENAME)
    

    and that is it really. The WHERE clause filters the record based on a filter match or a match with the existing items from the shuttle

    Andy

  • Vary the accounts based on the selection of feature in data form

    Hi all

    I use Hyperion Planning 11.1.1.0.

    I have a problem by varying the members accounts on the dataform based on the selection of members of the entity of the dimension of the page.

    Currently, we use the Begbalance as a member (column) in the dataform and kept hidden. And we set the value of Begbalance-> actual values to zero for accounts that correspond to a specific entity...

    Then, on the form, I put 'delete missing data... That way I can show the accounts that should appear for an entity.

    But the list of members of the entity has more than 200, and thus also the accounts.

    Therefore, it is very tedious to do this adjustment for them...

    Someone please you suggest a better way to achieve the same * (i.e. different accounts on the dataform based on a selection of entity?) *.

    Kind regards.

    Alicia

    Hello

    You use the technique that a lot of consultants allows you to control what is displayed on a form.
    How do you set the values, if you have an excel template that you just update and then send the data to essbase it can facilitate the management of it a little.

    See you soon

    John
    http://John-Goodwin.blogspot.com/

  • Cant' import images of Photos because "it is not enough free space on the volume of your library to import the selected items.

    Hey guys,.

    So I tried to import some ~ 8 GB of photos on my mac, but the Photos app gives me the following message: "there isn't enough free space on the volume of your library to import the selected items. It is estimated that you need at least X.XX GB of additional free space. »

    Where X.XX represents the amount of GB it says that I need but it changes everytime that I reopen the application to attempt an import.

    My mac has currently 44.4 GB so I don't know why this issue is coming.

    Any help would be great!

    Thanks in advance,

    Andres

    Where is your library?  If it's on an external HD and how the drive is formatted?

    Have you tried to repair the library according to this document from Apple: library of your repair?

    What version of PHotos do you use?

  • Appearance of the selected item

    Overall, I like the appearance of the Explorer of Windows Vista.  However, when an item is selected, the color of the selected item is so light that it is (for me) almost not visible.  I can change the classic theme, but really prefer to make just the darker outline.  How would I go to do this?

    Hello

    Panel Setup/Customize/Windows color and appearance of the control, use the slider to increase the intensity. There is no additional controls beyond that for aero colors. Good luck, Rick Rogers, aka "Crazy" - Microsoft MVP http://mvp.support.microsoft.com Windows help - www.rickrogers.org

  • How to detect when the selected item ObjectListField changed?

    I expanded the ObjectListField to implement a scroller of marquee style iPod for long lines of text that will disappear from the screen. So far, I have everything works well, and it works as I expect... when it fires.

    I'm having a problem to find a way to make reliable activate. It doesn't seem to be any method I can substitute or any earpiece I can use that fires when the current list item is changed. I first tried setSelectedIndex substitution. That worked sometimes, because apparently the OS is not call setSelectedIndex when he wants to change the item selected, it does something else.

    Then I tried the substitution of navigationMovement and manually call the code to start the timer, but that no longer works (I was the substitution of method navigationMovement of the ListField, maybe I should have done the Manager instead?). But anyway this approach does work for the version of the storm of my application because the storm never calls navigationMovement.

    Then I tried to use a fieldChangeListener, but apparently who don't get fired for the selection.

    Finally in despiration I tried substitution of drawListRow, only qualifying when index equals the selectedRow. But my code of scroll calls invalidate, so of course it just causes a loop infinite drawListRow, slow down the device and not even starting the scroll, because whenever the timer is started, it cancels the old one.

    Anyone have any ideas on what I can do here? Thank you.

    Good end I could not fieldChangeNotify to the fire, no matter which I overrided, even with the first setting the listener. It only seems fair to shoot during the selection change event. One thing to note, I use an objectlistfield, not an ObjectChoiceField... maybe you are thinking as well to another area?

    Thanks for the help anyway, in the end I was able to get the desired effect by modifying the code slightly to reuse the same animation timer rather than create a new one when the selected item changes. The timer is started in the constructor of the ListField. Works very well.

  • Change the content of the page based change the selection box

    Hi all

    I want to create a page with 2 box selection and 1 table below

    • Selection box
      • Box1: 1-12 (months of the year)
      • Box2: 2010-2015 (year between 2010 and 2015)
    • Table
      • Get data from view GET_DATA_SALARY. This view having a 4 column: NAME, SALARY, FAC_MONTH, FAC_YEAR
      • This table will be based on the selected value of 2 boxes above change

    Please help me solve this problem.

    Thank you

    To put it simply, add a button that submits the page.

    Add a where clause clause to your report

    where FAC_MONTH = P_MONTH

    and FAC_YEAR = P_YEAR

    Gus

  • How can we make a visible element on the screen based on the selection of an existing menu in the same screen

    February 2015 release OPA

    How can we make a visible element on the screen based on the selection of an existing menu in the same screen.

    I have a list box and a text box in the same screen.

    I have a visibility rule on the text box saying that it is only available for one of the selection in the menu dropdown.

    problem is now unless I hit the button next to the screen and return to the original screen the text box does not appear.

    Is there a solution to more to come this problem.

    Please help me

    The feature you describe is called "dynamic visibility" (http://documentation.custhelp.com/euf/assets/devdocs/february2015/PolicyAutomation/en/Default.htm#Guides/Policy%20Modeling%20User%20Guide/Interviews/Screens/Add_questions_to_screens.htm#Dynamic). It allows to control the visibility of another article on the same screen, without writing a separate rule of visibility and click on Submit.

    Using out-of-the-box functionality, you can have dynamic visibility based on Boolean values and value lists (but not regular drop-down lists).

    The example in the February 2015 User Guide based on a Boolean value on the same screen. See slide 27 of the bridge-features and benefits for an example of what it looks like to a list of value: http://www.oracle.com/technetwork/apps-tech/policy-automation/overview/opafeb2015featuresbenefits-2431219.pdf

    If you are wondering what is a list of values, see here: http://documentation.custhelp.com/euf/assets/devdocs/february2015/PolicyAutomation/en/Default.htm#Guides/Policy Modeling User Guide/Value_lists/What_is_a_value_list.htm

    See you soon,.

    Jasmine

  • Tabular returns lines based on the selection list

    Howdy-

    An element of the selection list is used to select a job title.

    The tabular presentation returns lines of documents to be considered annually by the title of the post.

    A single column in a tabular form (the number of the document) is defined as a link so that the user can open and read the document.

    It works beautifully.

    But...

    Some job titles return a row of five documents, still others return more than a hundred, so when paging is used to move to the next set of lines in tabular form, updates the selection list and the selection is lost.  I have the Page Action selection list element when the modified value to Redirect and set the value, but the Type of Source is static that may be my problem.

    How can I use pagination while maintaining the value of the selection list?

    Thanks in advance.

    Alexandra

    Request Express 4.2.2.00.11 (by the way, I don't have our network administrator do a update to this version?)

    the value of the default selection on a hidden item list. When you select from the drop-down list, set the item also hid from the selected item.

Maybe you are looking for

  • Slate 10 HD: Android &amp; HP

    Is the Android operating system a priority for HP? Can you let us know why you are so slow and behind competitors with updated Android OS on your shelves?

  • Shutdown of R500 protected with SD card problems

    Hello I have an annoying problem with my Portege R500. When I try to stop my laptop after it wake up from suspend mode, it freezes and doesn't complete the closing (it stops in the last screen before stopping.The funny thing is that this only happens

  • Best scanner code for 6 s iPhone?

    I just got an iPhone 6s... first smartphone ever for me! How to scan qr codes that you see everywhere? And other codes bars too? If I need an app for that, that one is the best, please? Thank you very much for your help!

  • 10.5.8 update Snow Leopard disc

    Here are the details on my computer: Model name: iMac Model identifier: Processor name: Intel Core 2 Duo Processor speed: 2.66 GHz Number of processors: 1 Total number of cores: 2 L2 Cache Memory: 6 MB Memory: 4 GB When I bought this computer (fall 2

  • Pavilion dm4 - 1063cl: Bios word password screen beep &amp; not able to enter characters

    I boot to see the Bios password screen.The system seems continuous short beeps.I'm not able to enter the password or any character to go beyond the the Bios password screen.Sometimes a character, indicated by *, is entered in the password box but not