Class display objects visible=false

Hi there,
I have an app that displays XML as items. I am taking the createLayout() and trying to create a class that i can call from my custom component rather than having tons of code in the same file. The issue i am having is that when i call it, and run/debug, the display objects (text,links,date..) all have their visible property set to false. This happens even though I set the property to true in my code. Please help!
package com.ryancanulla.utils
     import flash.display.Sprite;
     import flash.events.MouseEvent;
     import flash.net.URLRequest;
     import flash.net.navigateToURL;
     import flash.text.TextFormat;
     import mx.collections.XMLListCollection;
     import mx.containers.Canvas;
     import mx.containers.HBox;
     import mx.containers.VBox;
     import mx.controls.CheckBox;
     import mx.controls.ComboBox;
     import mx.controls.LinkButton;
     import mx.controls.Text;
     public class CreateLayout extends Sprite {
     //     Display Vars
          private var vBox:VBox;
          private var hBox:HBox;
          private var titleText:LinkButton;
          private var itemInfo:Text;
          private var abstract:Text;
          private var archive:CheckBox;
          private var rateItem:ComboBox;
          private var category:ComboBox;
          private var container:VBox;
          private var clickURL:Text;
          private var canvas:Canvas;
          private var titleFormat:TextFormat;
          public function CreateLayout(listCollection:XMLListCollection)
               listCollection = listCollection;
               container = new VBox();
               var categoryLabels:Array = new Array("Health","Industrial","Emerging Tech","Food & Ag");
               var rateLabels:Array = new Array("Positive","Neutral","Negative");
               for(var i:int=0; i<listCollection.length; i++) {
                    canvas = new Canvas();
                    hBox = new HBox();
                    titleText = new LinkButton();
                    titleFormat = new TextFormat();
                    itemInfo = new Text();
                    abstract = new Text();
                    archive = new CheckBox();
                    rateItem = new ComboBox();
                    category = new ComboBox();
                    clickURL = new Text();
                    titleText.label = listCollection.getItemAt(i).title;
                    titleText.addEventListener(MouseEvent.CLICK, getURL);
                    titleText.width = 400;
                    clickURL.text = listCollection.getItemAt(i).clickurl;
                    clickURL.visible = false;
                    clickURL.includeInLayout = false;
                    itemInfo.text = listCollection.getItemAt(i).source + " | " + listCollection.getItemAt(i).date;
                    itemInfo.y = 25;
                    abstract.text = listCollection.getItemAt(i).abstract;
                    abstract.y = 42;
                    abstract.visible = true;
                    abstract.includeInLayout = true;
                    abstract.width = 400;
                    abstract.height= 60;;
                    archive.label = "Archive";
                    category.prompt = "Category";
                    category.dataProvider = categoryLabels;
                    category.rowCount = categoryLabels.length;
                    category.visible = false;
                    category.includeInLayout = false;
                    category.width = 95;
                    category.height = 20;
                    rateItem.prompt = "Rate";
                    rateItem.dataProvider = rateLabels;
                    rateItem.visible = false;
                    rateItem.includeInLayout = false;
                    rateItem.width = 95;
                    rateItem.height = 20;
                    canvas.addChild(titleText);
                    canvas.addChild(clickURL);
                    canvas.addChild(itemInfo);
                    canvas.addChild(abstract);
                    canvas.addChild(hBox);
                    hBox.addChild(archive);    
                    hBox.addChild(category);
                    hBox.addChild(rateItem);
                    hBox.y = abstract.y + 60;
                    hBox.percentWidth = 80;
                    hBox.percentHeight = 80;
                    //archive.addEventListener(Event.CHANGE, toggleArchive);    
                    container.addChild(canvas);         
               container.x = 10;
               container.y = 10;
               container.visible = true;
               addChild(container);
        // Called when someone clicks on the titleLink. This function pulls the
        // origional website URL up in a seperate browser window
        private function getURL(e:MouseEvent):void {
                  var link:LinkButton = e.currentTarget as LinkButton;
                  var canvas:Canvas = link.parent as Canvas;
                  var clickURL:Text = canvas.getChildAt(1) as Text;
                  var url:URLRequest = new URLRequest(clickURL.text);
                  navigateToURL(url);
               trace(clickURL.text);
Where I instantiate the class. List collection is an XMLListCollection which contains XML data.
private var createLayout:CreateLayout;
createLayout = new CreateLayout(listCollection);

container is from the Vbox class so I don't see that here and there might be something in there that is causing some problem.
But I don't think that is the only problem. I think this seems like the same problem that you have going in your other post.
I don't see anyplace that you addChild your CreateLayout instance. container has been added to your CreateLayout instance, but where is the CreateLayout instance added to some other display list.
Also it looks like almost everything you add to canvas is set to be invisible. So without knowing what is in a Canvas instance it is hard to know what would show up anyways.

Similar Messages

  • Accessing display object on the stage from another class

    I've googled this to no avail, I've only found how to manipulate the stage itself and not a display object on it, and I'm noob enough to not be able to figure it out from there. :/
    I have a movie clip on the main timeline with instance name displayName. I created a button that should change what frame displayName goes to (in order to...did you guess it?! diplay the Name of the button. Awesome. )
    So I am trying to write the code in a reusable fashion and have the buttons all linked to a class called GeoPuzzle. Inside GeoPuzzle I instantiate a touch event and run the code. However, the function has to be able to change displayName in the main part of the timeline and, of course, the compiler says displayName doesn't exist because I'm in a class and I'm talking about the stage.
    Here is the simplified code in the class:
    package  com.freerangeeggheads.puzzleography {
        import flash.display.MovieClip;
        import flash.events.TouchEvent;
        public class GeoPuzzle extends MovieClip {
            //declare variables
            public function setInitial (abbrev:String, fullName:String, isLocked:Boolean):void {
                //set parameters
                this.addEventListener(TouchEvent.TOUCH_BEGIN, geoTouchBeginHandler);
            public function GeoPuzzle (): void {
            public function geoTouchBeginHandler (e:TouchEvent): void {
                   e.target.addEventListener(TouchEvent.TOUCH_END, geoTouchEndHandler);
                   //some other methods
                   nameDisplay.gotoAndStop(e.target.abbrev);
            public function geoTouchEndHandler (e:TouchEvent): void {
                //some other methods
               nameDisplay.gotoAndStop("USA");
    The lines in bold are my problem. Now this code doesn't actually execute as is so if you see an error in it, yeah, I have no idea what the problem is, but it DID execute before and these lines still gave me trouble so I'm trying to troubleshoot on multiple fronts.
    How can I tell displayName to change it's current frame from within display object class?
    Thanks!

    if displayName is a GeoPuzzle instance, use:
    package  com.freerangeeggheads.puzzleography {
        import flash.display.MovieClip;
        import flash.events.TouchEvent;
        public class GeoPuzzle extends MovieClip {
            //declare variables
            public function setInitial (abbrev:String, fullName:String, isLocked:Boolean):void {
                //set parameters
                this.addEventListener(TouchEvent.TOUCH_BEGIN, geoTouchBeginHandler);
            public function GeoPuzzle (): void {
            public function geoTouchBeginHandler (e:TouchEvent): void {
                   e.target.addEventListener(TouchEvent.TOUCH_END, geoTouchEndHandler);
                   //some other methods
                   this.gotoAndStop(this.abbrev);
            public function geoTouchEndHandler (e:TouchEvent): void {
                //some other methods
               this.gotoAndStop("USA");

  • BitmapData class - displaying and resizing

    Hi Forum,
    I'm trying to teach myself flex by working through the tutorial videos on here and searching the net, however i have become a bit stuck with image manipulation.
    I want to make a Flash solution that loads in an image and with let the user zoom in and out and pan around.  I'm having problems quite early on particularly with displaying the resized image correctly and was wondering someone could provide some advice....some simple advice.  I have development experience but very little knowledge with flash/flex components.
    So far i have loaded the image, and i've been playing around with the bitmapdata class and managed to resize it.  But when i output it the image is smaller but has a background that takes up the original size.  I Think this may be solved somehow with the rec property?  But i can't get it to work. 
    I wanted to load the image at its original size and then resize it smaller to fit a view area, then when someone wants to zoom increase the size of the displayed image with the overflow not showing.
    So far my output looks like this:
    As you can see the image is smaller but it must still be taking up the same size or something because the canvas has scoll bars on it.  Whats happening.  Also when the image is bigger than the canvas how can i not have scroll bars and hide the overflow.  Here is my code:
    mx:Application xmlns:mx="http://www.adobe.com/2006/mxml"
         layout="absolute"
         backgroundGradientAlphas="[1.0, 1.0]"
         backgroundGradientColors="[#FBF8F8, #FBF8F8]"
         applicationComplete="Init()">
         <mx:Script>
              <![CDATA[
                   private var imgLoader:Loader;
                   private function Init():void{
                        imgLoader = new Loader();
                        //Image location string
                        var imageURL:String = "http://www.miravit.cz/australia/new-zealand_panoramic/new-zealand_panoramic_01.jpg"
                        //Instantiate URL request
                        var imageURLReq:URLRequest = new URLRequest(imageURL);  
                        imgLoader.contentLoaderInfo.addEventListener(Event.COMPLETE, imgLoadCompleted);
                        imgLoader.contentLoaderInfo.addEventListener(ProgressEvent.PROGRESS, progressListener);
                        //Begin image load
                        imgLoader.load(imageURLReq);
                   private function imgLoadCompleted(event:Event):void{
                   //On completion of image load     
                        progressBar.visible = false;
                        var scale:Number = .1;
                        //Set matrix size
                        var m:Matrix = new Matrix();
                        m.scale (scale,scale);
                        var bmd:BitmapData = new BitmapData(this.width, this.height);
                        bmd.draw(this.imgLoader,m);
                        var bm:Bitmap = new Bitmap(bmd);
                        auctionImageContainer.source = bm;
                   private function progressListener(event:ProgressEvent):void {
                    //Update progress indicator.
                         progressBar.setProgress(Math.floor(event.bytesLoaded / 1024),Math.floor(event.bytesTotal / 1024));
              ]]>
         </mx:Script>
         <mx:Canvas height="583" width="674">
              <mx:Canvas id="cvsImage"
                   borderColor="#BABEC0" borderStyle="solid" left="152" right="151" top="177" bottom="121">
                   <mx:Image id="auctionImageContainer" />
                   <mx:ProgressBar id="progressBar"
                             mode="manual" 
                               x="84.5" y="129"
                               labelPlacement="center"
                               themeColor="#6CCDFA" color="#808485" />
              </mx:Canvas>
         </mx:Canvas>
    </mx:Application>
    Thanks for any help
         LDB

    MediaTracker isn't about the number of images. I've been bitten in the ass by this before -- images seem to magically refuse to appear, or only appear on reloads, and it's because paint() got called before the image was loaded. MediaTracker fixed it.
    I don't know what you mean about images not working in constructors though. You can do that.
    Here's some code that works to display an image (for me anyway):
    import java.awt.*;
    import java.awt.event.*;
    import java.awt.image.*;
    public class Test {
      public static void main(String[] argv) {
        Image i = Toolkit.getDefaultToolkit().createImage("image.jpg");
        Frame f = new Frame("Test");
        MediaTracker mt = new MediaTracker(f);
        mt.addImage(i, 1);
        try {
          mt.waitForAll();
        } catch (InterruptedException e) {
          e.printStackTrace();
        f.addWindowListener(new WindowAdapter() {
          public void windowClosing(WindowEvent e) {
            System.exit(0);
        f.add(new Displayer(i));
        f.pack();
        f.setVisible(true);
      private static class Displayer extends Canvas {
        private Image i;
        Displayer(Image i) { this.i = i; }
        public void paint(Graphics g) {
          g.drawImage(i, 0, 0, null);
        public Dimension getPreferredSize() {
          return new Dimension(i.getWidth(null), i.getHeight(null));
        public Dimension getMinimumSize() { return getPreferredSize(); }
    }

  • Loading a video overtop another display object

    Hi All,
    I am trying to load a video on click of a button after my animation plays out.. however, when I load it, it appears behind better_mc.. I tried using addChildAt(); but that doesnt' solve the problem. Any help would very appreciated! Below is the snippet of the code that shows both objcets loaded:
    var test:VideoLoader = new VideoLoader("TestVideo.f4v");
    test.load();
    addChild(test.content);
    OverwriteManager.init(OverwriteManager.AUTO);
    //Buttons Invisible
    breathe_mc.learn_btn.visible = false;
    breathe_mc.video_btn.visible = false;
    live_mc.learn_btn.visible = false;
    live_mc.video_btn.visible = false;
    sleep_mc.learn_btn.visible = false;
    sleep_mc.video_btn.visible = false;
    feel_mc.learn_btn.visible = false;
    feel_mc.video_btn.visible = false;
    CustomEase.create("myCustomEase", [{s:0,cp:1.14999,e:1.4},{s:1.4,cp:1.65,e:1}]);
    CustomEase.create("myCustomEase2",[{s:0,cp:0.97,e:1.22},{s:1.22,cp:1.47,e:1}]);
    var timeline:TimelineLite = new TimelineLite({onComplete:showBreathe});
    addChild(removeChild(better_mc));
    Thank you!

    I am not familiar with the classes you are using, but for any load processing I am familiar with, the content is not readily available since it takes time to happen.  So you might try just using
       addChild(test);
    As far as that last line of code you show goes....
       addChild(removeChild(better_mc));
    That's not serving any purpose I can see other than placing better_mc on top of anything else, and has the same net effect as just using addChild(better_mc);  The removeChild method returns the object being removed, so it is essentially saying to add the child right after you remove it - which still places it atop anything else.  If you just get rid of that line altogether you might find the video sitting atop everything as you want.

  • Class with objects compile error in Java 1.5.0 and 1.4.2.05

    Hi, I have some problems with creating objects to my java program.
    See below:
    JAVA, creating new class object.
    class AccountTest {
         public static void main(String[]args) {
         Account olesAccount = new Account(123456676756L, "Ole Olsen", 2300.50);
         olesAccount.deposit(1000.0); //Input of 1000$ to account
         double balance = olesAccount.findBalance(); //Ask object about balance!
         System.out.println("Balance: " +balance);
    ERRORS, from compiler (javac):
    AccountTest.java:7: cannot find symbol
    symbol : class Account
    location: class AccountTest
    Account olesAccount = new Account(123456676756L, "Ole Olsen", 2300.50);
    ^
    AccountTest.java:7: cannot find symbol
    symbol : class Account
    location: class AccountTest
    Account olesAccount = new Account(123456676756L, "Ole Olsen", 2300.50);
    ^
    2 errors
    This error occurs with both java 1.5.0 RC and 1.4.2.05
    */

    Assuming you haven't forgotten to compile the Account class, tt seems to be a problem with visibility. Are you sure your classpath is set up correctly and that the class Account is visible to the AccountTest driver?
    I'd try moving the Account out of whatever package it's in right now and making it public. Then, restrict acces from there.

  • EventListener function specific to generated display object container

    This has to be simple, if only I knew how. I'm an AS3 newbie,
    and am having difficulty setting up multiple specific
    EventListeners within a code generated display object container.
    I am generating a 'page' (Sprite) with a heap of 'cards'
    (Sprites) on it. Each of those cards, in turn, contains a selection
    of text boxes and other objects generated from database output
    using a 'for' loop.
    My hope is to attach an EventListener to each 'card' so that
    a MouseEvent will let me manipulate the data that lead to the
    content of that actual card (the i-th iteration of my for loop).
    I've been playing with everything I can think of (limited
    repertoire of thoughts though) and the best I've managed is for my
    EventListener to access the final set of data, whichever 'card' I
    click on.
    I've summarised and attached my code for the function, and
    would appreciate any advice (however basic) on how to get back to
    the i-set of data from the EventListener attached to the i-th card.
    I can handle the PHP and MySQL side of things but am fumbling my
    way into the OOP of AS3.
    Cheers
    Dougal

    Another way would be to extend Sprite and add an id value.
    Something like:
    package{
    import flash.display.Sprite;
    public class MySprite extends Sprite {
    private var _id:int;
    public function MySprite(id:int){ _id = id; }
    public function get id():int { return _id; }
    And then in your code you'd just make instance of MySprite,
    passing it i:
    // build the cards and text boxes and add them to the
    reviewPage
    for (var i:int = 1; i < (cardsRequired+1); i++) {
    // setup the locations for all the objects
    var displayCard:Sprite = new MySprite(i);
    You can then get i in the event listener function by using
    the id getter:
    function accessThisData(e:MouseEvent):void{
    trace(e.target.parent.id);
    Dave -
    www.offroadfire.com
    Head Developer
    http://www.blurredistinction.com
    Adobe Community Expert
    http://www.adobe.com/communities/experts/

  • Display objects in ALV

    Is it possible to display an internal table of objects using ALV?
    I've tried to do so using the following code:
    TYPES object_table_type TYPE TABLE OF REF TO zcl_classname.
    DATA object_table TYPE object_table_type.
    ... Fill object_table with objects ...
    DATA alv_table TYPE REF TO cl_salv_table.
    CALL METHOD cl_salv_table=>factory
              IMPORTING r_salv_table = alv_table
              EXPORTING t_table = object_table.
    However, during the factory method, I get a dump because of a dynamic type conflict. The call proceeds as follows (I've omitted all formal parameters but t_table, which is the only relevant one in this case):
              1. cl_salv_table=>factory( object_table )
              2. cl_salv_table->set_data( object_table )
              3. cl_salv_data_descr=>describe_table( object_table )
    At this point, the describe_table method calls cl_abap_structdescr=>describe_by_data_ref( ) on a reference to a line in object_table. It expects the method to return an instance of cl_abap_structdescr, but it obviously returns an instance of cl_abap_refdescr, as the table line is in fact a reference to an object. Consequently, a dump occurs.
    From this, it looks like ALV just wasn't built to cater for displaying objects. That's understandable, as flat structures are a lot simpler to cater for, but disappointing, given the professed push towards object orientation, and considering how integral ALV is to a lot of ABAP development.
    Does anyone know if there is any other, standard way to do this? If there isn't, I'll either write code to automatically convert my objects to structures, or extend cl_salv_model_list and make my own ALV table for displaying objects. (I'd love to extend cl_salv_table, but it's final. Annoyingly. I'd rather final classes be banned than have them be the default option. But that's a rant for another day.)

    That's what I figured. Though I'm not sure I agree with you on the complex structure argument. Structures, too, can contain complex components - other structures, references, table types, and so on. I'm not actually sure how the ALV deals with these. I assume it might only display the components of the structure that are elementary. If this is the case, an identical solution for a table of objects would be appropriate, using read-only public attributes or attributes with corresponding GET_ methods. (But I could be totally off.)
    For the purposes of this argument, objects are exactly the same as structures. Objects just have methods. Or that's how it seems to me.
    Edited by: James Geddes on Jun 18, 2010 4:20 PM

  • Insufficient authorization to display object Message Mapping

    Hi there
    Every now and then when I try and open a message mapping object I get this error: Insufficient authorization to display object Message Mapping. I then restart my Integration Builder then it works again.
    Any Idea how I would fix this?
    Thanks,
    Jan

    hi,
    apart from what was said you can try changing
    com.sap.aii.ib.util.server.auth.activation
    parameter in exchangeprofile to false
    if you don't use any data-dependent authorizations
    then you should never see this error
    maybe this will help
    but remember that if you want to use data-dependent authorizations
    in the future you need to put it back to true again
    Regards,
    Michal Krawczyk

  • ALV using ABAP Classes and Objects

    Hi All,
    I am trying to print the values in my internal table using ALV, using ABAP classes and objects. Here the title for columns are picked based on the title specified in the data element. I want to set the title of my columns by my own. how to achieve this ?. Please provide me a sample code if possible.
    thanks & regards,
    Navneeth.K

    Hello Navneeth
    The following sample report shows how to build and modify a fieldcatalog (routine <b>BUILD_FIELDCATALOG_KNB1</b>).
    *& Report  ZUS_SDN_ALVGRID_EVENTS
    REPORT  zus_sdn_alvgrid_events.
    DATA:
      gd_okcode        TYPE ui_func,
      gt_fcat          TYPE lvc_t_fcat,
      go_docking       TYPE REF TO cl_gui_docking_container,
      go_grid1         TYPE REF TO cl_gui_alv_grid.
    DATA:
      gt_knb1          TYPE STANDARD TABLE OF knb1.
    PARAMETERS:
      p_bukrs      TYPE bukrs  DEFAULT '2000'  OBLIGATORY.
    *       CLASS lcl_eventhandler DEFINITION
    CLASS lcl_eventhandler DEFINITION.
      PUBLIC SECTION.
        CLASS-METHODS:
          handle_hotspot_click FOR EVENT hotspot_click OF cl_gui_alv_grid
            IMPORTING
              e_row_id
              e_column_id
              es_row_no
              sender.
    ENDCLASS.                    "lcl_eventhandler DEFINITION
    *       CLASS lcl_eventhandler IMPLEMENTATION
    CLASS lcl_eventhandler IMPLEMENTATION.
      METHOD handle_hotspot_click.
    *   define local data
        DATA:
          ls_knb1     TYPE knb1,
          ls_col_id   TYPE lvc_s_col.
        READ TABLE gt_knb1 INTO ls_knb1 INDEX e_row_id-index.
        CHECK ( ls_knb1-kunnr IS NOT INITIAL ).
        CASE e_column_id-fieldname.
          WHEN 'KUNNR'.
            SET PARAMETER ID 'KUN' FIELD ls_knb1-kunnr.
            SET PARAMETER ID 'BUK' FIELD ls_knb1-bukrs.
            CALL TRANSACTION 'XD03' AND SKIP FIRST SCREEN.
          WHEN 'ERNAM'.
    *        SET PARAMETER ID 'USR' FIELD ls_knb1-ernam.
    *        NOTE: no parameter id available, yet simply show the priciple
            CALL TRANSACTION 'SU01' AND SKIP FIRST SCREEN.
          WHEN OTHERS.
    *       do nothing
        ENDCASE.
    *   Set active cell to field BUKRS otherwise the focus is still on
    *   field KUNNR which will always raise event HOTSPOT_CLICK
        ls_col_id-fieldname = 'BUKRS'.
        CALL METHOD go_grid1->set_current_cell_via_id
          EXPORTING
            is_row_id    = e_row_id
            is_column_id = ls_col_id.
      ENDMETHOD.                    "handle_hotspot_click
    ENDCLASS.                    "lcl_eventhandler IMPLEMENTATION
    START-OF-SELECTION.
      SELECT        * FROM  knb1 INTO TABLE gt_knb1
             WHERE  bukrs  = p_bukrs.
    * Create docking container
      CREATE OBJECT go_docking
        EXPORTING
          parent                      = cl_gui_container=>screen0
          ratio                       = 90
        EXCEPTIONS
          OTHERS                      = 6.
      IF sy-subrc <> 0.
    *   MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    *              WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
    * Create ALV grid
      CREATE OBJECT go_grid1
        EXPORTING
          i_parent          = go_docking
        EXCEPTIONS
          OTHERS            = 5.
      IF sy-subrc <> 0.
    *   MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    *              WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
    * Set event handler
      SET HANDLER:
        lcl_eventhandler=>handle_hotspot_click FOR go_grid1.
    * Build fieldcatalog and set hotspot for field KUNNR
      PERFORM build_fieldcatalog_knb1.
    * Display data
      CALL METHOD go_grid1->set_table_for_first_display
        CHANGING
          it_outtab       = gt_knb1
          it_fieldcatalog = gt_fcat
        EXCEPTIONS
          OTHERS          = 4.
      IF sy-subrc <> 0.
    *   MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    *              WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
    * Link the docking container to the target dynpro
      CALL METHOD go_docking->link
        EXPORTING
          repid                       = syst-repid
          dynnr                       = '0100'
    *      CONTAINER                   =
        EXCEPTIONS
          OTHERS                      = 4.
      IF sy-subrc <> 0.
    *   MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    *              WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
    * ok-code field = GD_OKCODE
      CALL SCREEN '0100'.
    END-OF-SELECTION.
    *&      Module  STATUS_0100  OUTPUT
    *       text
    MODULE status_0100 OUTPUT.
      SET PF-STATUS 'STATUS_0100'.
    *  SET TITLEBAR 'xxx'.
    ENDMODULE.                 " STATUS_0100  OUTPUT
    *&      Module  USER_COMMAND_0100  INPUT
    *       text
    MODULE user_command_0100 INPUT.
      CASE gd_okcode.
        WHEN 'BACK' OR
             'END'  OR
             'CANC'.
          SET SCREEN 0. LEAVE SCREEN.
        WHEN OTHERS.
      ENDCASE.
      CLEAR: gd_okcode.
    ENDMODULE.                 " USER_COMMAND_0100  INPUT
    *&      Form  BUILD_FIELDCATALOG_KNB1
    *       text
    *  -->  p1        text
    *  <--  p2        text
    FORM build_fieldcatalog_knb1 .
    * define local data
      DATA:
        ls_fcat        TYPE lvc_s_fcat.
      CALL FUNCTION 'LVC_FIELDCATALOG_MERGE'
        EXPORTING
    *     I_BUFFER_ACTIVE              =
          i_structure_name             = 'KNB1'
    *     I_CLIENT_NEVER_DISPLAY       = 'X'
    *     I_BYPASSING_BUFFER           =
    *     I_INTERNAL_TABNAME           =
        CHANGING
          ct_fieldcat                  = gt_fcat
        EXCEPTIONS
          inconsistent_interface       = 1
          program_error                = 2
          OTHERS                       = 3.
      IF sy-subrc <> 0.
    * MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    *         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
      LOOP AT gt_fcat INTO ls_fcat
              WHERE ( fieldname = 'KUNNR'  OR
                      fieldname = 'ERNAM' ).
        ls_fcat-hotspot = abap_true.
        ls_fcat-scrtext_s  = '<short text>'.  " short text of column
        ls_fcat-scrtext_m = '<medium text>'.  " medium text of column
        ls_fcat-scrtext_l   = '<long text>'.  " longtext text of column
        ls_fcat-tooltip      = '...'.  " ALV control: Tool tip for column header
        ls_fcat-coltext    = '...'.   " ALV control: Column heading
        MODIFY gt_fcat FROM ls_fcat.
      ENDLOOP.
    ENDFORM.                    " BUILD_FIELDCATALOG_KNB1
    Regards
      Uwe

  • [svn] 3149: Fix bugs introduced by the display object sharing optimization.

    Revision: 3149
    Author: [email protected]
    Date: 2008-09-08 16:58:35 -0700 (Mon, 08 Sep 2008)
    Log Message:
    Fix bugs introduced by the display object sharing optimization. This checkin should fix ordering problems when dynamically adding/removing graphic elements, and ordering problems when changing graphic element properties that require a display object (rotation, alpha, filters, etc).
    Bugs:
    MXMLG-219: BitmapGraphic component content always rendered from 0, 0 origin.
    MXMLG-220: setting visible property of Rect and Ellipse does nothing.
    MXMLG-222: setting the alpha of a rectangle changes z-order when there are 3 or more rectangles
    SDK-16754: Z-order incorrect when a Group is present
    QA: Yes - the test files from these bugs (or something equivalent) should be added to our standard test suite
    Reviewer: Deepa
    Ticket Links:
    http://bugs.adobe.com/jira/browse/MXMLG-219
    http://bugs.adobe.com/jira/browse/MXMLG-220
    http://bugs.adobe.com/jira/browse/MXMLG-222
    http://bugs.adobe.com/jira/browse/SDK-16754
    Modified Paths:
    flex/sdk/trunk/frameworks/projects/flex4/src/flex/core/Group.as
    flex/sdk/trunk/frameworks/projects/flex4/src/flex/graphics/BitmapGraphic.as
    flex/sdk/trunk/frameworks/projects/flex4/src/flex/graphics/graphicsClasses/GraphicElement .as

    This is the great thread ;-)
    My favorite threads are below.
    Munky posted great reply :8}
    SQL Query Help
    order in a connect by

  • Display Object list Button(Shift+F11) in Transaction code SE09

    I am Facing problem Due to version upgradation .
    Problem is
    I can See Display Object list Button(Shift+F11) in Transaction code SE09 of SAP4.6c.
    But i cant found it in Transaction code SE09 of ECC6.0.
    Could any buddy ans me where can i find that Button to display object list .
    Thank you in advance
    Deepak.

    Hi Deepak -
    By chance did you post this message to the wrong discussion forum?  This forum is for Financial Performance Management related products, most of which are not yet even based on SAP NetWeaver technology where transaction SE09 would be relevant.
    Your question seems more suitable to me in the SAP Software Logistics forum.
    <a class="jive_macro jive_macro_community" href="" __jive_macro_name="community" modifiedtitle="true" __default_attr="2149"></a>
    Please try to post there in hope of receiving a satisfactory answer.
    Best regards,
    [Jeffrey Holdeman|http://wiki.sdn.sap.com/wiki/display/profile/Jeffrey+Holdeman]
    SAP BusinessObjects
    Enterprise Performance Management
    Regional Implementation Group

  • Applying a filter to multiple display objects

    I have a large amount of btn's that load full size images when clicked. I simply want to add a filter, scaleX and scaleY to each of those buttons and  I know there is a better method then typing each btn name with an eventListener for the Mouse_Over and Mouse_Out events. I understand that I need to create a variable of a new filter and then apply it to the display object. Like so..
    var glow:GlowFilter = new GlowFilter(0x0066FF, 1, 10, 10);
    function hover(event:MouseEvent):void
    pic1_btn.filter = new Array(glow);
    pic1_btn.scaleX = 1.02;
    pic1_btn.scaleY = 1.02;
    pic1_btn.addEventListener(MouseEvent.MOUSE_OVER, hover);
    function noHover(event:MouseEvent):void
    pic1_btn.filter = new Array();
    pic1_btn.scaleX = 1;
    pic1_btn.scaleY = 1;
    pic1_btn.addEventListener(MouseEvent.MOUSE_OUT, noHover);
    So if I were to continue this, I would have to type out pic1_btn, pic2_btn, pic3_btn and so on to apply a filter to each object and also type out the object name for each listener. NUTS! So my question is what is the best way to approach this? Thanks for your help.

    Thank you for that information yesterday, it was really helpful.
    OK so what I have is a pretty simple album. At the top of hierarchy I have a file named "loader.swf" that requires a password and then loads the "album.swf" then depending on the button that is selected on the "album.swf" an additional .swf is loaded. These additional .swf's contain the thumbnail buttons which we are discussing and when those buttons are clicked an external full size .jpg is loaded. Following are the actions from the main timeline.
    var picLoader:Loader = new Loader();
    bar_mc.alpha = 0;
    function progressHandler(event:ProgressEvent):void
          var myprogress:Number = event.target.bytesLoaded/event.target.bytesTotal;
          addChild(bar_mc);
          addChild(myTextField_txt);
          bar_mc.alpha = 100;
          bar_mc.scaleY = myprogress;
          myTextField_txt.text = Math.round(myprogress*100)+"%";
    picLoader.contentLoaderInfo.addEventListener(ProgressEvent.PROGRESS, progressHandler);
    function imageLoaded(event:Event):void
          addChild(picLoader);
          removeChild(myTextField_txt);
          removeChild(bar_mc);
          picLoader.x = (stage.stageWidth - picLoader.width)/2;
          picLoader.y = (stage.stageHeight - picLoader.height)/2;
    picLoader.contentLoaderInfo.addEventListener(Event.COMPLETE, imageLoaded);
    function removeFull(event:MouseEvent):void
          picLoader.unload();
          removeChild(picLoader);
    picLoader.addEventListener(MouseEvent.CLICK, removeFull);
    On the main timeline I have an instance of a movie clip called "mcThumbs". Within this movieclip I have different pages on different layers and 12 thumbnails per page.
    And the actions for mcThumbs
    stop();
    function picClick(event:MouseEvent):void
          this.parent.picLoader.load(new URLRequest(event.target.name + ".jpg"));
    for(var a:uint=1; a<=76; a++)
          this["newborn"+String(a)].addEventListener(MouseEvent.CLICK, picClick);
    function hover(event:MouseEvent):void
          event.currentTarget.scaleX = 1.02;
          event.currentTarget.scaleY = 1.02;
    function noHover(event:MouseEvent):void
          event.currentTarget.scaleX = 1;
          event.currentTarget.scaleY = 1;
    for(var i:uint=1; i<=76; i++)
          this["newborn"+String(i)].addEventListener(MouseEvent.MOUSE_OVER, hover);
          this["newborn"+String(i)].addEventListener(MouseEvent.MOUSE_OUT, noHover);
    function goBack(event:MouseEvent):void
          if(currentFrame == 1)
                gotoAndStop(totalFrames);
          else
                prevFrame();
    function goForward(event:MouseEvent):void
          if(currentFrame == totalFrames)
                gotoAndStop(1);
          else
                nextFrame();
    prev_btn.addEventListener(MouseEvent.CLICK, goBack);
    next_btn.addEventListener(MouseEvent.CLICK, goForward);
    This is where the issue arises. If you hover over a thumbnail button and then go to an different page, that same thumbnail button will remain visible behind the thumbnails of that page.

  • Hi all visible false udf in marketing document

    hi all,
    i want to visible false udf in the marketing document.but field not show in the forms object.
    how is possible.

    thanks to replr but i haven't got udf in the active form event.
    If pVal.FormType = "142" Then 'Purchase Order Form
                    If pVal.EventType = SAPbouiCOM.BoEventTypes.et_FORM_LOAD And BubbleEvent = True And FLAG = False Then
                                       oFormAPOrder = SBO_Application.Forms.GetFormByTypeAndCount(pVal.FormType, pVal.FormTypeCount)
                            'Form = SBO_Application.Forms.ActiveForm
                            Dim oItem As SAPbouiCOM.Item
                            oItem = oForm.Items.Item("U_UIN")
                            oItem.Visible = False
    end if
    end if
    i read in forum that u have to catch form with -142 then u get the udf of the form.
    but i tried my problem not solved.
    Regards
    Rajkumar

  • Set visible=false in Label not removing its space in screen

    Hi All,
    I have three labels ony by one having width=100% for all.
    For some reason, now I want to make 2nd label invisible in
    the screen.
    So I set visible="false" for the 2nd label. Now I cannot the
    see the text displayed by the 2nd Label, but I can see the space
    occupied by the Label.
    I mean that, now i am getting the first label text, and have
    blank row which has the text earlier, but not now and thrid row
    with 3rd label text.
    Also I checked that, if I set the height of the 2nd Label to
    0 then also its not completely removing the 2nd row, only
    possibility I found was completely comment the code for the 2nd
    Label is the only way to hide the 2nd row :)
    Any help would be appreciated.

    Hi Sujit,
    Thanks for giving an useful tip which is new to me. But still
    I can see a little space between the first and 3rd label.
    Now this little space comes from the default space between
    the controls. After few trials I found that there is a property
    called "verticalGap" for the containter which holds these 3 labels.
    I set the value to 0(zero) for verticalGap. Now the issue resolved
    Thanks for a useful post

  • When do display objects get a size?

    I am testing parts of an application as actionscript-only and then merge them into a flash project.
    Now, when testing, this works fine
    var s1:Sprite = new Something1();
    addChild(s1);
    var s2:Sprite = new Something2();
    s2.y = s.y + s1.height;
    addChild(s2);
    things align perfectly. When I do the same in flash, s1.height is 0 and objects sit on top of each other ....?

    some components or children of components are not rendered as soon as they're instantiated.
    in that situation, you can use the render event or one enterframe loop or a time delay (of less than 100ms) to access display properites like width and height of your object:
    var whatever:Whatever=new Whatever();
    whatever.addEventListner(Event.RENDER,f);
    stage.invalidate();
    function f(e:Event):void{
    trace(whatever.width,whatever,height);
    if you have a custom class, the object may not be drawn in your class until much later than the next stage render event.  in that situation, you should dispatch an event from your class and use a listener for that event.

Maybe you are looking for