View stack call

Lets say i have a component with the name "Accounts" in this
component it has a view stack named "stkView". How do i reference
the "stkView" in the main application?

Usually you just chain the ids to the ViewStack.
So if the component instance is created in AS:
private var acct:Accounts = new Accounts();
private function init():void{
acct.stkView.selectedChild = "cont2";
}

Similar Messages

  • Why do I need to declare "defaultButton" ? (In a component form part of view stack)

    After doing some research and some help from FlexGuy in another thread, I realize that I need to make sure I have custom components initialized before accessing parts of the component.  Just recently I was thrown for a long time when I tried to first click on a form field that was part of a component in my view stack, I'd get:
    TypeError: Error #1009: Cannot access a property or method of a null object reference.
        at mx.managers::FocusManager/focusInHandler()[C:\autobuild\galaga\frameworks\projects\framew ork\src\mx\managers\FocusManager.as:601]
    With the debugger it's occuring in the focusInHandler method of FocusManager.as: (apparently _defaultButton is null.)
    // restore the default button to be the original one
                    if (defButton && defButton != _defaultButton)
                        defButton.emphasized = false;
                        defButton = _defaultButton;
                       _defaultButton.emphasized = true;
    This prompted me, on a whim, to delcare a defaultButton:
    <mx:Form id="empForm" defaultButton="{submitButton}">
    which refers to my submit button:
    <mx:Button id="submitButton" click="submitEmployee()" label="{submitLabel}"/>
    My question, is why is this necessary? In some examples I don't see this declared at all, but I seem to need it? (I'm calling creationPolicy="all" to make sure my components are initialized but I still seem to have to this defaultButton declared?)

    It's a way of proving that you are able to purchase content from that country's store i.e. that you have a valid billing address in it
    From Why can’t I select None when I edit my Apple ID payment information? - Apple Support :
    If you changed your country or region
    When you change the country or region of an existing Apple ID, you must provide a payment method and update your billing options. If you want to remove your payment method after you change the country or region, you can change your payment information to None.

  • Flex 4 custom component with children inserted directly into view stack

    I give up. Hopefully I am just missing something easy, but I feel like I am pulling teeth trying to get this to work. All I want is a custom 'wizard' component whose children are placed within a ViewStack and beneath the ViewStack there is a next and back button. Here are some code excerpts to illustrate my approach:
    WizardGroup.as:
    [SkinPart(required="true")]
    public var nextBt:Button = new Button();
    [SkinPart(required="true")]
    public var backBt:Button = new Button();
    [SkinPart(required="true")]
    public var stack:ViewStackSpark = new ViewStackSpark();
    WizardGroupSkin.mxml:
    <s:VGroup width="100%" height="100%"
              paddingBottom="10" paddingTop="10" paddingLeft="10" paddingRight="10">
         <container:ViewStackSpark id="stack" width="100%" height="100%">
              <s:Group id="contentGroup" width="100%" height="100%" minWidth="0" minHeight="0"/>
         </container:ViewStackSpark>
         <s:HGroup horizontalAlign="right" width="100%">
              <s:Button id="nextBt" label="Next" enabled="{hostComponent.permitNext}" enabled.last="false"/>
              <s:Button id="backBt" label="Back" enabled="{hostComponent.permitBack}" enabled.first="false"/>
         </s:HGroup>
    </s:VGroup>
    While this comes very close to working, the major problem is that the children of the WizardGroup component are not added as children of the viewstack. Instead, they are added as children of the contentGroup. So the viewstack will always only have one child: contentGroup.
    I also tried the approach of binding the contents of the view stack to the children of contentGroup, but with Spark containers, there is no way to access an array of children or array of elements (ie, there is no contentGroup.getChildren() or contentGroup.getElements()).  Finally, I tried making the id of the ViewStackSpark "contentGroup" but since the ViewStackSpark inherits from BorderContainer, Flex complains at runtime that it can't cast the BorderContainer to Group.
    Help would be greatly appreciated.
    Thanks everyone.
    Josh

    I finally figured it out. The trick is to set the default property of the WizardGroup to a public member array I am calling "content"
    [DefaultProperty("content")]
    public class WizardGroup extends TitleWindow
        [SkinPart(required="true")]
        public var nextBt:Button = new Button();
        [SkinPart(required="true")]
        public var backBt:Button = new Button();
        [Bindable]
        public var content:Array;
    And then within the skin, bind the content of the viewstack to the hostComponent's content array:
            <s:VGroup width="100%" height="100%"
                      paddingBottom="10" paddingTop="10" paddingLeft="10" paddingRight="10">
                <container:ViewStackSpark id="stack" width="100%" height="100%" content="{hostComponent.content}"/>
                <s:HGroup horizontalAlign="right" width="100%">
                    <s:Button id="nextBt" label="Next" enabled="{hostComponent.permitNext}" enabled.last="false"/>
                    <s:Button id="backBt" label="Back" enabled="{hostComponent.permitBack}" enabled.first="false"/>
                </s:HGroup>
            </s:VGroup>

  • View stack issue creation

    Lets say you have the following view stack with the following
    components in it. When i turn on creationPolicy="all"
    Any of the components will not call their
    creationComplete="loadData()" any ideas as to why?

    The problem is in one view stack page i have a drop down list
    that you can select different companies then in the other viewstack
    page it has a display of charts. So lets say the drop down country
    list is in selectedIndex=1 the charting is in selectedIndex=2 when
    i select different companies from the dropdown component in
    selectedindex=1 it will change the data in selectedindex=2

  • How to view my call log from a month ago

    I have a few numbers that I need from last month and I want to view my call log history from December how do I do that?

    Contact your carrier to download your call history, you might have to log into your provider account to see the details.

  • How do I view incoming call telephone numbers from Verizon web site?

    I am trying to view incoming call numbers from the Verizon web site on my account.  I can do this on my past staements but need to see the incoming call numbers between the last statement and current (today)?  Can anyone help me?

    If you are the Account Owner and logged in as such ... once you're logged into your on-line My Verizon account, scroll down a bit to My Usage, then click the blue View Usage Details.  Under Minutes, click the blue Breakdown of Recent Activity.  Next to Current Call Log for Line, use the drop-down to choose the line you want to view, then highlight that line and you should see the call log.

  • SM30 / View Maintainance Call problem with Position button

    We are having an issue with the position button on Tcode SM30 and Function View Maintenance Call. When we press the position button and try to enter a material number (matnr element, with links to the correct databases) and then click on ok, it doesn't found materials that we know are on the Ztable.
    Experimenting, I found that entering the complete number with all the leading zeroes finds the correct item, so my guess is that the Position button doesn't use the conversion alpha exit. A test with a Ztable where the made up code fills up the entire code space shows it finds the data correctly, so it seems that completion is the issue, reinforcing the idea that the conversion alpha exit (wich is correctly associated to the matnr domain) is not working in positioning.
    Any pointers or ideas will be appreciated.

    Hi
    Use this function modules for the material number
    CONVERSION_EXIT_ALPHA_input
    CONVERSION_EXIT_ALPHA_output
    I think it will work..find in debug wat value s coming

  • Setting selectedIndex on view stack after removal

    I'm having an issue where when I remove an element from a ViewStack its not selecting the previous item in the list. It keeps snapping back to index 0.
    here's some simple code:
    <?xml version="1.0" encoding="utf-8"?>
    <s:WindowedApplication
              xmlns:fx="http://ns.adobe.com/mxml/2009"
              xmlns:s="library://ns.adobe.com/flex/spark"
              xmlns:mx="library://ns.adobe.com/flex/mx"
              creationComplete="onCreationComplete();"
    >
              <fx:Script>
                        <![CDATA[
                                  import spark.components.Label;
                                  import spark.components.NavigatorContent;
                                  private function onCreationComplete():void {
                                            for (var i:int = 0; i < 10; i++) {
                                                      addNew();
                                  private function removeCurrent():void {
                                            var child:NavigatorContent = layouts.selectedChild as NavigatorContent;
                                            if (child) {
                                                      layouts.removeChild(child);
                                  private function addNew():void {
                                            var title:String = "item " + layouts.length;
                                            var content:NavigatorContent = new NavigatorContent();
                                            content.label = title;
                                            var label:Label = new Label();
                                            label.text = title;
                                            content.addElement(label);
                                            layouts.addElement(content);
                        ]]>
              </fx:Script>
              <s:layout>
            <s:VerticalLayout/>
        </s:layout>
        <!-- Drop down list to show the view stack, uses double data binding -->
              <s:DropDownList id="dropDown" width="200" labelField="label" dataProvider="{layouts}" selectedIndex="@{layouts.selectedIndex}" />
              <!-- TabBar to show the view stack, uses single data binding -->
              <s:TabBar id="tabBar" width="100%" dataProvider="{layouts}" />
              <!-- Content view stack -->
              <mx:ViewStack id="layouts">
              </mx:ViewStack>
              <!-- Buttons to test -->
              <s:Button label="remove" click="removeCurrent();"/>
              <s:Button label="add" click="addNew();" />
    </s:WindowedApplication>
    when you remove the current item, the stack selects item 0. I cannot seem to override this. I want the view stack to select the previous item in the list

    Using SuperTabBar from the flexlib solves this issue. http://flexlib.googlecode.com/svn/trunk/examples/SuperTabNavigator_Sample.swf
    when you delete a tab, the bar selects the next one in line. Am I wrong in expecting this functionality out of the box in the spark componenet library?

  • Can a 3D view be called from JavaScript

    I have spent many hours looking for this solution, but haven't found the answer yet. I want to have a Flash movie call a 3D view.
    Thanks in advance for your help.

    runtime.setView( 'viewname_goes_here', boolean_animate );
    e.g. in a doc-level context if the view is called "homeView" and you want to switch to it instantly (without the default camera animation):
    getAnnots3D(pageNum)[0].context3D.runtime.setView('homeView', false);

  • Why cant i view my call package+ add ons ?

    My first post, i hope this isnt going to be the norm.
    as said, i cant view my call package or add ons etc.
    all i get is ...
    "  We're sorry...
    We have noticed you already have one of our great package deals. Please call one of our helpful advisors on 0800 800 150 who will advise you on how to change your package. "
    to be honest, im fed up with calling the 0800 number to eventually only to speak to someone , in India I assume, who doesnt seem to know what they are doing....ive rang 4 times by the way...so for this problem i thought I would try here first.
    Rob.
    Solved!
    Go to Solution.

    Hi Rob,
    Welcome to the forum.
    Sounds like you're already on a special offer or deal, but I can take a look at your account if you want, can you email in your forum username and BT account details to me?
    You can get our email address by clicking on my username.
    Thanks,
    Stephanie
    Stephanie
    BTCare Community Manager
    If you like a post, or want to say thanks for a helpful answer, please click on the Ratings star on the left-hand side of the post. If someone answers your question correctly please let other members know by clicking on ’Mark as Accepted Solution’.

  • Order highlighted when product view is called.

    Hi All,
    In APO , We have one custom report which display all orders. By clicking on order number , it displays its product view. Here , product view contains many orders so it would become little tedious to find that order from long list.
    Is there any way that product view is called with order number being highlighted so it become very easy to locate.
    Rer,
    Prashant

    We have created custom interactive report which shows orders based on plant and product mentioned on selection screen. Here , if we click on any order within report , its product view is getting called. I am able to call product view but if there are many orders for that product location then it one has to search order number in product view. We need somehow if we click on order number within custom report , product view should be called with order number being highlited in product view ( in blue text ) so that user would know by which order number this product view was called.
    I am calling call transaction "/SAPAPO/RRP*" from my custom report , here product view is getting called but I need to search order number ( need to remember order number while clikcing ) from long list in product view.
    Does any on know any fucntion module or any way to highlight order number when product view is called.

  • Treo 755 resets when I try to view my call log

    Can someone point me in the right direction to correct this problem.  The phone resets whenever I try to view my call log.  I assume the call log is corrupt somehow but I do not know how to correct it. 
    Thanks!!!
    Post relates to: Treo 755p (Sprint)

    i had this same issue. i know hardreset will resolve this one, but after syncing the phone again to the computer and tried viewing the log it will shut off. if this is caused by data corruption, then, just hardreseting the device will not work cos it will still sync the corrupted data to the phone again after the hardreset. someone told me that before syncing the phone after the hardreset i should rename the backup folder on my username. but renaming it will not sync any of my third party applications back and my call logs. my call logs are important to me, so if i can not open it from the phone, is there a way to view it on my computer?..
    thanks..
    Post relates to: None

  • I am not able to view my call log

    I have been unable to view my call log for a couple of weeks now. everytime i click on the call log it goes straight back to the main screen.i have been into the apple store who have advised me to update it which i have just done but it still doesnt work.

    Fixed this by downloading TenFourFox version 10

  • How to View Voice Call Detail for 12 Month History?

    Hello, I asked via Chat but it keeps locking up. I know there's a way to view voice call history by phone number for a 12 month period, but I can't see how to view this for months prior to the current month. When I select a prior month, it just shows a usage graph.
    How do I view monthly voice call history with phone number detail?
    Thanks!

    See if this helps:
    Re: How can I access call history from over a year ago?

  • Hbox in view stack does not update width

    Hi there,   I'm working on flash builder and I have four hboxes nested inside a view stack. I dynamically populate each hbox with images grabbed from the database. For some reason only the visible hbox correctly updates its' width while the other 3 hbox takes on the width of this one so I end up with all four hbox having the same width. This is a problem when I have lots of images in one than the other and some of them gets cut off.
    The hboxes do not have scroll bars as the viewstack has a mouse easing scroller function attached to it - the hbox scrolls according to the position of the mouse.
    Am I doing something wrong here?
    <mx:Canvas height="110"
                       width="663"
                       visible.loginState = "false"
                       x="10"
                       y="577" horizontalScrollPolicy="off" verticalScrollPolicy="off" id="viewStackContainer">
                <mx:ViewStack id="myViewStack" creationPolicy="all"
                              borderStyle="none">
                    <!-- Books Library -->
                    <mx:HBox horizontalAlign="left" verticalScrollPolicy="off" horizontalScrollPolicy="off" verticalAlign="middle" horizontalGap="0" id="books" />
                    <!-- EBooks Library -->
                    <mx:HBox horizontalAlign="left" verticalScrollPolicy="off" horizontalScrollPolicy="off" verticalAlign="middle" horizontalGap="0" id="ebooks" />
                    <!-- Recordings Library -->
                    <mx:HBox horizontalAlign="left" verticalScrollPolicy="off" horizontalScrollPolicy="off" verticalAlign="middle" horizontalGap="0" id="recordings" />
                    <!-- Readings Library -->
                    <mx:HBox horizontalAlign="left" verticalScrollPolicy="off" horizontalScrollPolicy="off" verticalAlign="middle" horizontalGap="0" id="readings" />
                </mx:ViewStack>
            </mx:Canvas>

    Hi thanks for your reply. As the hbox gets populated i need it to resize itself. Once each hbox has been populated with the images I attach a function to the viewstack which allows me to scroll the hbox with mouse position - so it scrolls horizontally depending on where the mouse is in relation to the viewstack. So as you can see I need by this point for each hbox to have resized in order to correctly calculate my scrolling function.  The bizarre thing is the selected Index hbox displays all the images but the rest of the hboxes takes on the same width as this one and this is a problem because some of my other hbox contains more images.  As a test I set the selected Index of the viewStack to be the third Hbox, then I restarted the application and now all the hbox takes on the wdith of this one.   I am creating a library of thumbnails which is dynamically driven. It's not possible for me to predetermine the width of each. Do you have any suggestions for this?

Maybe you are looking for