Flex SWFLoader LocalConnection Click events problem

Hi,
I'm experiencing a issue while trying to integrate a SWF movie with Flex for using it to create an AddOn for Xcelsius SDK. The idea is to create a Map Addon , just like the ones that are included with Xcelsius but with a custom map of the region where i live.
The swf communicates with Flex through a LocalConnection and sends a message each time a region has been clicked, Flex retrieves this event and copies a data row to another place in the Excel Spreadsheet, so other diagramms can feed themselves with this data and represent it or whatever.
This localconnection works just fine when i execute the Flex Project alone, but when i generate the Addon (using the AddOn packager), this stops working. I introduced a label to use as debug so each time a message from the swf file comes , Flex will write the message in this Label.
What i saw, and that is the strange part of this issue. is that this label is being Updated also in Xcelsius, because when i leave the Preview mode i can see on the edit window that the label has changed its text, but not during the Preview mode (it is where i need it to work)
I am using Xcelius SDK 2.0.1 Hotfix 3 , Flex Builder 2, Flash cs5 (tried with AS2, AS3 and exporting for multiple browser)
Has anybody experience the same issue?
Know somebody a howto, tutorial or sample of a Custom map in Xcelsius?
Where can i find good Documentation? (i have already the samples and tutorials from SAP)
Thanks in advance,
Alex.

How are you embedding the map?
Xcelsius does not use Flash maps (so does not embed them in a SWF).
You may be better off using SVG for your map and compiling it into the Flex project using the [Embed] metadata like you can for SVG.
Or like I did with AnyMap parse and draw the SVG on the fly instead.
That way you don't need to embed a Flash map and use the LocalConnection.
Regards
Matt

Similar Messages

  • HasEventListener and click event problem

    Hi!
    Is it possible that hasEventListener() method has a bug? Whenever I remove event listener(using removeEventListener method) from a click event (which's been added using AS), hasEventListener always returns true. However event listener method gets removed. I've also tried some other events and I got mixed results, some have worked, some haven't.
    Thanks, regards

    Thanks for replying.
    I go to DO_HANDLE_EVENT as you said. There is already written something as below by wizard.
    class  : ZL_BT115QH__DETAILS_IMPL
    method: DO_HANDLE_EVENT
    code: 
    CASE htmlb_event_ex->event_server_name.
    *     Added by wizard
        WHEN 'PAYM'.                                            "#EC NOTEXT
          EH_ONPAYM( htmlb_event    = htmlb_event
                      htmlb_event_ex = htmlb_event_ex ).
    I added button in ZL_BT115QH__MAINWINDOW_IMPL but I try to handle in ZL_BT115QH__DETAILS_IMPL
    I thought this might cause the problem.
    Which DO_HANDLE_EVENT method you mentioned?
    method in  ZL_BT115QH__MAINWINDOW_IMPL or ZL_BT115QH__DETAILS_IMPL ??

  • SWFLoader/Image complete event problem (bug?)

    I have an SWFLoader in my application whose content is
    dynamically bound to a datagrid for loading different images.
    Depending on the new image size I want to make some adjustments,
    etc. to the SWFLoader itself... that's not important for now.
    The problem is that if I take the width of the SWFLoader
    instance on the "complete" event, it gives the value for the
    PREVIOUS image setting so my math function is useless.
    Try this to see what I mean:
    [Bindable]
    public var imageSource:String;
    private function temp():void {
    mx.controls.Alert.show("imgLoader.width: "+imgLoader.width);
    <mx:Button click="imageSource='someImageURL'" />
    <mx:SWFLoader id="imgLoader" autoLoad="true"
    source="{imageSource}" complete="temp()" />
    if you implement the above code, and assuming that
    imageSource is a null string upon initialization, you will get a
    value of "0" for the imgLoader instance's width when you load a new
    image.
    To get around this in Flex 1.5 I could use doLater(this,
    "temp") but doLater appears to have been removed in Flex 2.0.
    My current work around is to modify the above code as
    follows:
    private function temp():void {
    this.addEventListener("enterFrame", blorch);
    private function blorch(b:Event):void {
    mx.controls.Alert.show("imgLoader.width: "+imgLoader.width);
    this.removeEventListener("enterFrame", blorch);
    feels like a hack to me... is there no way to get this to
    work without using the above functions? Sort of seems pointless to
    have removed "doLater" just to make me write a function that
    essentially does the same thing in Flex 2.0. I tried using the
    "resize" event in place of "complete" and that works... if the
    image loaded is a different size than the previous one. If the
    image is the same size (as is often the case in my application)
    then it doesn't work.
    Any suggestions Adobe/Macromedia, fellow developers?

    Flex harUI -
    two solutions to this then are:
    1) use the callLater() function or
    2) extend the SWFLoader class...
    I don't want to increase my component files so I will stick
    with the callLater() setup.
    Haskasu -
    I tried init. It has the same result as complete. If I insert
    code like this: init="mx.controls.Alert.show(imgLoader.width)" I
    get the width for the *previous* setting (same as complete) and not
    the new setting.

  • Item Click Event problems

    Hi, I've been using an itemclick event on a datagrid that I
    created, and it's been great up until now. I've just added a button
    column to the table, and obviously the itemclick event is stopping
    my button from being pressed. Is there any way I can exclude this
    column from the itemclick event?
    Thanks :)

    I've found a work around thanks. But I'll elaborate anyway...
    My datagrid has 4 columns... a, b, c, d. Column d has a
    button in each row.
    I have an itemclick event so that the my event fires when the
    row is clicked, but I didn't want this to happen when the button
    was clicked (which is inside the item that is clicked)
    What I did in the end was do a check for the column number of
    the event and fire a different event if it was d :)

  • Right Click Event Problem in Matrix

    Hi all,
    I want to remove line of matrix except last line?. How i manage the DataSource after removing rows in the matrix ? If you have any samples please give me??
    Regards,
    Suresh.G

    RIGHT_CLICK_BEFOREACTION(ref SAPbouiCOM.ContextMenuInfo eventInfo, out bool BubbleEvent, SAPbouiCOM.Application oSboApplication, SAPbobsCOM.Company oCompany)
                BubbleEvent = true;
                oForm.EnableMenu("1293", true);
    remove row one by one.
    i think this will help you.

  • MouseOut event seems to cancel Click event

    Im using a state for rollovers of a button, and a state for
    the click of the same button, this causes a problem when the user
    clicks the button. Instead of the click state being activated
    instead i see a brief blinking of the click state and then suddenly
    the app reverts to the mouseOut state, how can I tell FLEX that the
    click event is more important then the mouseOut event?
    EXAMPLE
    <mx:Canvas mouseOver="currentState='rollOver'"
    mouseOut="currentState='rollOut'"
    click="currentState='clicked'">
    in this example, when you click the canvas you will end up at
    the "rollOut" state instead of the "clicked" state but it appears
    the clicked state may be displayed for a brief moment as the app
    kind of blinks before showing the "rollOut" state. Oh and I've
    tried to remove the event listener on click but it doesn't appear
    to be fired as the event listener is not removed. HELP!?!

    "octagonatron" <[email protected]> wrote in
    message
    news:g8feue$iee$[email protected]..
    > Im using a state for rollovers of a button, and a state
    for the click of
    > the
    > same button, this causes a problem when the user clicks
    the button.
    > Instead of
    > the click state being activated instead i see a brief
    blinking of the
    > click
    > state and then suddenly the app reverts to the mouseOut
    state, how can I
    > tell
    > FLEX that the click event is more important then the
    mouseOut event?
    >
    > EXAMPLE
    > <mx:Canvas mouseOver="currentState='rollOver'"
    > mouseOut="currentState='rollOut'"
    click="currentState='clicked'">
    >
    > in this example, when you click the canvas you will end
    up at the
    > "rollOut"
    > state instead of the "clicked" state but it appears the
    clicked state may
    > be
    > displayed for a brief moment as the app kind of blinks
    before showing the
    > "rollOut" state. HELP!?!
    How bout
    mouseOut="currentState!='clicked'?currentState='mouseOut':currentState='clicked'"
    or mouseOut="mouseOutHandler()"
    private function mouseOutHandler():void{
    if (currentState!='clicked') currentState='mouseOut';

  • Activating Click event on Item Renderer only

    Hey. I'm working on a s:list and a click event problem. I have everything working just fine on the component and linking, but as you probably guessed, the event cues when anything on the s:list is clicked, including the scroll bar or empty space.
    Is there a quick fix to make the event only cue when an Item Renderer is clicked inside the list? Help would be much appreciated, I've been trying to solve this problem for a while.
    Thanks!
    RKaster

    Hi RKaster,
    do you need the reference to the item renderer by force or could you immagine a different approach? If you could work around that you could use the change event instead of the click event. The change event gets fired whenever the selection of items in the list change. A click on an item renderer of course will change the selection if the underlying item isn't already selected.
    If you can't work around the need of an item renderer reference you should experiment with the mouseChildren property of the List component (inherited from DisplayObjectContainer, see http://bit.ly/dhqCFS). IMHO of course
    Regards,
    Thilo

  • Click event on SWFLoader

    Hello,
    In my FLEX application i have a SWFLoader where i load some wsf files that are located in others places in the web. Some of the swf files loaded contain an hyperlink associated and, when the swf file is clicked, a new web page is opened.
    So, i need to count the number of clicks made in the SWFLoader but, in the case when the swf file has an hyperlink associated, the click event is not fired. What can i do to detect if a click was made in the SWFLoader?
    Thanks in advance for your help.

    Hi carlos_sousa4,
    Check the below code loading the Flash SWF in to Flex application.. and handling a click event on the Flash SWF Button in the Flex app..
    <?xml version="1.0" encoding="utf-8"?>
    <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml"
    layout="vertical"
    backgroundAlpha="0"
    backgroundColor="#FFFFFF">
    <mx:Script>
      <![CDATA[
       import mx.controls.Button;
       import mx.controls.Alert;
       private var loadedSWFMainTimeline:*;
       public function onSWFLoadComplete():void {
        Alert.show("onSWFLoadComplete");
        //loadedSWFMainTimeline gets you a reference to the Flash SWF MainTimeline
        loadedSWFMainTimeline = swfLoader.content;
        if(loadedSWFMainTimeline)
         var _button:SimpleButton = loadedSWFMainTimeline.button_btn as SimpleButton;
         _button.addEventListener(MouseEvent.CLICK,onMCButtonClick);
       public function onMCButtonClick(event:MouseEvent):void {
        if(loadedSWFMainTimeline)
         Alert.show("HELLO SWF LINK CLICKED");
      ]]>
    </mx:Script>
    <mx:SWFLoader id="swfLoader" source="assets/flashswf.swf" complete="onSWFLoadComplete();"/>
    </mx:Application>
    Note : In the above code  button_btn is the Flash button instance of the SWF file and the corresponding type in the Flex will be SimpleButton...In your post you said that you are using a HyperLink so may be you should flash.text.TextField datatype instead of SimpleButton.
    Try to debug by putting a break point at onSWFLoadComplete function and watch the loadedSWFMainTimeline varibale you will come to know the exact type and the other parameters in the SWF file.
    If this post answers your question or helps, please kindly mark it as such.
    Thanks,
    Bhasker Chari

  • Problem in Button Click Event

    Hi All!
    In Good issue I have create One Button and in click event I call one function, but my problem when click this button it call my function 2 times. Please help me fix this problem, my code below:
    Private Sub SBO_Application_ItemEvent(ByVal FormUID As String, ByRef pVal As SAPbouiCOM.ItemEvent, ByRef BubbleEvent As Boolean) Handles SBO_Application.ItemEvent
            If ((pVal.FormType = 720 And pVal.EventType <> SAPbouiCOM.BoEventTypes.et_FORM_UNLOAD) And (pVal.Before_Action = True)) Then
                oForm = SBO_Application.Forms.GetFormByTypeAndCount(pVal.FormType, pVal.FormTypeCount)
                If ((pVal.EventType = SAPbouiCOM.BoEventTypes.et_FORM_LOAD) And (pVal.Before_Action = True)) Then
                    oItem = oForm.Items.Item("2")
                    oNewItem = oForm.Items.Add("MyBtnP", SAPbouiCOM.BoFormItemTypes.it_BUTTON)
                    oNewItem.Top = oItem.Top
                    oNewItem.Height = oItem.Height
                    oNewItem.Width = oItem.Width + 5
                    oNewItem.Left = oItem.Left + oItem.Width + 5
                    oButton = oNewItem.Specific
                    oNewItem.Visible = True
                    oButton.Caption = "Fixed Asset"
                End If
                Select Case pVal.ItemUID
                    Case "MyBtnP"
                        If SAPbouiCOM.BoEventTypes.et_CLICK Then
                            Try
                                oMatrix = oForm.Items.Item("13").Specific
                                colItemCode = oMatrix.Columns.Item("1")
                                Dim Row As Integer = oMatrix.RowCount
                                For i As Integer = 1 To Row
                                    oEditItemCode = colItemCode.Cells.Item(i).Specific
                                    If oEditItemCode.Value.ToString() <> "" Then
                                       AssetMaster_Add(oEditItemCode.Value.Trim())
                                    End If
                                Next
              Me.SBO_Application.SetStatusBarMessage("Inserted Fixed Asset Successfully.", SAPbouiCOM.BoMessageTime.bmt_Short, False)
                                Exit Sub
                            Catch ex As Exception
                            End Try
                        End If
                End Select
            End If
        End Sub

    Hi Tao,
    1. use et_ITEM_PRESSED instead of et_CLICK and combine it with BeforeAction:
    If SAPbouiCOM.BoEventTypes.et_ITEM_PRESSED and pval.BeforeAction = False Then
    2. generally i recommend you to use BeforeAction  instead of the old Before_Action (deprecated)
    i saw that in et_FORM_LOAD in top of your code
    lg David

  • I am using a Application in c dll calling from jni jar by java applet in firefox version 19.0 , the problem is click event message box will not working correct

    I am using a Application in c dll calling from jni jar by java applet in firefox version 19.0 , the problem is button click event message box or popup window will not working correctly. Please any one suggest me the steps to overcome this not responding or slowness in the responding problem of Button click event.

    Hello,
    In Firefox 23, as part of an effort to simplify the Firefox options set and protect users from unintentially damaging their Firefox, the option to disable JavaScript was removed from the Firefox Options window.
    However, the option to disable JavaScript was not removed from Firefox entirely. You can still access it from about:config or by installing an add-on.
    '''about:config'''
    # In the address bar, type "about:config" (with no quotes), and press Enter.
    # Click "I'll be careful, I promise"
    # In the search bar, search for "javascript.enabled" (with no quotes).
    # Right click the result named "javascript.enabled" and click "Toggle". JavaScript is now disabled.
    To Re-enable JavaScript, repeat these steps.
    '''Add-ons'''
    You can alternatively install an add-on that lets you disable JavaScript, such as
    *[https://addons.mozilla.org/firefox/addon/noscript/ No-Script] (to disable JavaScript on a per page basis, as required)
    *[https://addons.mozilla.org/firefox/addon/quickjava/ QuickJava] (to easily disable and enable JavaScript, automatic loading of images, and other content)
    Thank you and I hope this helps!

  • Opening New Browser window for click event on an image

    hi all,
    I want someone to help me out solving the problem of opening
    a new browser window on the mouse click event of an image or a
    button etc.... The new window would contain the datagrid details
    from the main window, but in an expanded form. If at all there is a
    solution, I even want to know whether there is anyway for sizing
    the poped up window,because I dont want the new poped up window to
    cover the entire screen.
    For getting better idea of my problem, the best example I
    could give is the popup window that appears when we click on the
    preview button while posting the message to the forum.
    Someone please do help me out in this regard.
    Thanks,
    amar.

    I'd definitely try to use a Flex popup... but the
    flash.net.navigateToURL method is a simple way to open a popup
    window in a new browser. You can pass any data needed by the new
    page using the URLRequest and/or URLVariables. The URL you navigate
    to could, of course, be another Flex application if necessary. I
    use this only when I need to open a popup window on another site,
    or an HTML formatter report or something similar.
    Concerning yourself with the size of the popup window may be
    a bad design choice also. I, for example, have my browser
    configured to open all popups in a new tab regardless of sizing
    constraints imposed by the designer. If it is absolutely necessary
    for you to have control over the size of your popup window, you
    should follow the advice given by others and use a Flex
    popup.

  • Possible bug - Missing click event when handling change event

    Using Flex 4.5 SDK, I have a spark ComboBox and a Button next to it for applying a filter according to ComboBox selection.
    I listen to both the ComboBox's change event & the Button's click event (for different functions).
    When I manually delete the ComboBox text value from its TextInput (i.e. changing selected index to -1) and immediately click on the Button,
    the click event-handler function is not being called and only the ComboBox's change event-handler function is executed.
    (Selecting a value from the ComboBox's list and clicking on the button triggers both methods on the right order.)
    There's also a state definition for the module, but it isn't being changed during these operations...
    Is this a bug or a correct behavior? Am I missing something here?
    Any workaround suggestions?
    (I thought of listening also to mouse-down or mouse-up on the button instead, but haven't tried it yet...)
    *** UPDATE ***
    When using the Button's mouseDown event the behavior is as expected, so there's a simple workaround.
    However, it seems to me like there's a bug with the Button's click event listener or something...
    *** UPDATE #2 ***
    I created a test application for that and couldn't reproduce the problem.
    Then I figured out the problem and solved it.
    It's a bit emmbarrasing, but I actually disabled the button (enabled=false) as in a child method of the change handling code...
    (If there is no value, don't allow applying the filter - It makes sense! )
    Anyway... No issue after all.
    However, I choose to leave this post (and not delete it) as an example of identifying and resolving a strange behavior in a complex application.

    There's no need.
    Please read the section UPDATE #2.

  • Click event on a swf

    I have a swf that has some simple actionscript to create a
    roll over. Problem is that i cant use a click event in my Flex now
    for when you click the swf. I made an invisible movieclip to act as
    a hit area, so when i click on the same swf but outside that hit
    area, it works. Any help would be apprecieated.
    Thanks

    I'm not sure if this is related, or if it will help, but...
    I've made a simple banner in Flex, then used that swf file in
    another project and the banner that I made works like it is its own
    application. Not sure if that will help.. but more information is
    always good.. haha.

  • Radio button's click event to script both ".presence" and ".mandatory" -- Need help !

    Hi all,
    I've adopted the script stated in HightlightOneRequiredField.pdf so that the print button in my form can detect and prevent null field before pop up the print dialog. It works fine.
    In my form, I've created a mandatory 2-radio buttons group with click event script written, using ".presence", in each button. When user clicks:
    Button A: make subform A visible and subform B invisible;
    Button B: make subform A invisible and subform B visible.
    Apart from the visibility of the subforms, what I want more is to add a .mandatory script (together with the click event) in the buttons to turn some fields' mandatory in the subforms on and off so that when user clicks:
    Button A: will also turn some fields' value type in subform A to be "User
    Entered-Required", whereas some of that in subform B to be "-
    optional";
    Button B: will turn the subform B's fields to "-Required" and subform A's
    fields back to "-optional"
    However no luck with me. When I press the print button after any of the radio buttons checked, the print dialog still show up even the subforms' fields are null as if those fields' value type always remain "-optional"
    I wonder if this problem is caused by Chinese binding name ? The script written in the radio button B is:
    FormA.presence = "invisible";
    FormB.presence = "visible";
    if (B1.mandatory = "disabled")
    B1.mandatory = "error";
    if (B2.mandatory = "disabled")
    B2.mandatory = "error";
    if (B3.mandatory = "disabled")
    B3.mandatory = "error";
    if (A1.mandatory = "error")
    A1.mandatory = "disabled";
    if (A2.mandatory = "error")
    A2.mandatory = "disabled";
    if (A3.mandatory = "error")
    A3.mandatory = "disabled";
    B1, B2 and B3 represent the Chinese fields' binding name in FormB
    A1, A2 and A3 represent the Chinese fields' binding name in FormA
    (The script in radio button A is reversed in this way.)
    Have I done something wrong in the above (click event) javascript?
    Please help.
    Thanks in advance.
    Alex

    Hi all,
    I've adopted the script stated in HightlightOneRequiredField.pdf so that the print button in my form can detect and prevent null field before pop up the print dialog. It works fine.
    In my form, I've created a mandatory 2-radio buttons group with click event script written, using ".presence", in each button. When user clicks:
    Button A: make subform A visible and subform B invisible;
    Button B: make subform A invisible and subform B visible.
    Apart from the visibility of the subforms, what I want more is to add a .mandatory script (together with the click event) in the buttons to turn some fields' mandatory in the subforms on and off so that when user clicks:
    Button A: will also turn some fields' value type in subform A to be "User
    Entered-Required", whereas some of that in subform B to be "-
    optional";
    Button B: will turn the subform B's fields to "-Required" and subform A's
    fields back to "-optional"
    However no luck with me. When I press the print button after any of the radio buttons checked, the print dialog still show up even the subforms' fields are null as if those fields' value type always remain "-optional"
    I wonder if this problem is caused by Chinese binding name ? The script written in the radio button B is:
    FormA.presence = "invisible";
    FormB.presence = "visible";
    if (B1.mandatory = "disabled")
    B1.mandatory = "error";
    if (B2.mandatory = "disabled")
    B2.mandatory = "error";
    if (B3.mandatory = "disabled")
    B3.mandatory = "error";
    if (A1.mandatory = "error")
    A1.mandatory = "disabled";
    if (A2.mandatory = "error")
    A2.mandatory = "disabled";
    if (A3.mandatory = "error")
    A3.mandatory = "disabled";
    B1, B2 and B3 represent the Chinese fields' binding name in FormB
    A1, A2 and A3 represent the Chinese fields' binding name in FormA
    (The script in radio button A is reversed in this way.)
    Have I done something wrong in the above (click event) javascript?
    Please help.
    Thanks in advance.
    Alex

  • ALV: Issue with double  click event after sorting the ALV

    Hello Experts,
    I have an internal table that populates an ALV grid. When the user doubleclicks a row, my method HANDLE_DOUBLE_CLICK returns the e_row-index value from the ALV Grid. I use this index value to read the internal table, then retrieve additional data.
    My problem is the user may sort the ALV grid before double clicking on a line. If this happens my internal table is not sorted to match the ALV grid, so reading the internal table with the e_row-index value returns the wrong information.
    When the double click event occurs, is it possible to capture the value in column 1 instead of a value for e_row-index?
    There is one more paramter in HANDLE_DOUBLE_CLICK for row id.   It is coming blank in debugging .  what is the purpose of this parameter and how i can make use of it ?
    Regards
    Vivek

    Hi,
    I am Posting The Code Which Uses Double Click Event.
    And This Code will provide the total information to you.
    REPORT  ZALVGRID_PG.
    TABLES: SSCRFIELDS.
    DATA: V_BELNR TYPE RBKP-BELNR.
    SELECTION-SCREEN BEGIN OF BLOCK B1 WITH FRAME TITLE TEXT-001.
    SELECT-OPTIONS: IRNO FOR V_BELNR.
    PARAMETERS: P_GJAHR TYPE RBKP-GJAHR.
    SELECTION-SCREEN END OF BLOCK B1.
    DATA: WA TYPE ZALVGRID_DISPLAY,
          ITAB TYPE STANDARD TABLE OF ZALVGRID_DISPLAY.
    DATA: IDENTITY TYPE REF TO CL_GUI_CUSTOM_CONTAINER.
    DATA: GRID TYPE REF TO CL_GUI_ALV_GRID.
    DATA: L_IDENTITY TYPE REF TO CL_GUI_CUSTOM_CONTAINER.
    DATA: L_TREE TYPE REF TO CL_GUI_ALV_TREE_SIMPLE.
    TYPE-POOLS: SLIS,SDYDO.
    DATA: L_LOGO TYPE SDYDO_VALUE,
          L_LIST TYPE SLIS_T_LISTHEADER.
    END-OF-SELECTION.
    CLASS CL_LC DEFINITION.
      PUBLIC SECTION.
        METHODS: DC FOR EVENT DOUBLE_CLICK OF CL_GUI_ALV_GRID IMPORTING E_ROW E_COLUMN.
    ENDCLASS.
    CLASS CL_LC IMPLEMENTATION.
      METHOD DC.
        DATA: WA1 TYPE ZALVGRID_DISPLAY.
        READ TABLE ITAB INTO WA1 INDEX E_ROW-INDEX.
        BREAK-POINT.
        SET PARAMETER ID 'BLN' FIELD WA1-BELNR.
        CALL TRANSACTION 'FB02'.
      ENDMETHOD.                    "DC
    ENDCLASS.
    DATA: OBJ_CL TYPE REF TO CL_LC.
    START-OF-SELECTION.
      PERFORM SELECT_DATA.
      IF SY-SUBRC = 0.
        CALL SCREEN 100.
      ELSE.
        MESSAGE E000(0) WITH 'DATA NOT FOUND'.
      ENDIF.
      INCLUDE ZALVGRID_PG_STATUS_0100O01.
      INCLUDE ZALVGRID_PG_LOGOSUBF01.
      INCLUDE ZALVGRID_PG_SELECT_DATAF01.
    INCLUDE ZALVGRID_PG_USER_COMMAND_01I01.
    ***INCLUDE ZALVGRID_PG_STATUS_0100O01 .
    MODULE STATUS_0100 OUTPUT.
      SET PF-STATUS 'AB'.
    *  SET TITLEBAR 'xxx'.
      IF IDENTITY IS INITIAL.
        CREATE OBJECT IDENTITY
        EXPORTING
          CONTAINER_NAME = 'ALVCONTROL'.
        CREATE OBJECT GRID
        EXPORTING
          I_PARENT = IDENTITY.
        CALL METHOD GRID->SET_TABLE_FOR_FIRST_DISPLAY
          EXPORTING
             I_STRUCTURE_NAME              = 'ZALVGRID_DISPLAY'
          CHANGING
            IT_OUTTAB                     = ITAB.
        CREATE OBJECT OBJ_CL.
        SET HANDLER OBJ_CL->DC FOR GRID.
        ENDIF.
        IF L_IDENTITY IS INITIAL.
          CREATE OBJECT L_IDENTITY
          EXPORTING
            CONTAINER_NAME = 'LOGO'.
          CREATE OBJECT L_TREE
          EXPORTING
            I_PARENT = L_IDENTITY.
          PERFORM LOGOSUB USING L_LOGO.
          CALL METHOD L_TREE->CREATE_REPORT_HEADER
            EXPORTING
              IT_LIST_COMMENTARY    = L_LIST
              I_LOGO                = L_LOGO.
          ENDIF    .
    ENDMODULE.                 " STATUS_0100  OUTPUT
    ***INCLUDE ZALVGRID_PG_LOGOSUBF01 .
    FORM LOGOSUB  USING    P_L_LOGO.
      P_L_LOGO = 'ERPLOGO'.
    ENDFORM.                    " LOGOSUB
    ***INCLUDE ZALVGRID_PG_SELECT_DATAF01 .
    FORM SELECT_DATA .
      SELECT RBKP~BELNR
             RBKP~BLDAT
             RSEG~BUZEI
             RSEG~MATNR
             INTO TABLE ITAB
             FROM RBKP INNER JOIN RSEG
        ON RBKP~BELNR = RSEG~BELNR
        WHERE RBKP~BELNR IN IRNO
        AND RBKP~GJAHR = P_GJAHR.
    ENDFORM.                    " SELECT_DATA
    ***INCLUDE ZALVGRID_PG_USER_COMMAND_01I01 .
    MODULE USER_COMMAND_0100 INPUT.
      CASE SY-UCOMM.
        WHEN 'EXIT'.
          LEAVE PROGRAM.
        WHEN 'CANCEL'.
           EXIT.
           ENDCASE.
    ENDMODULE.                 " USER_COMMAND_0100  INPUT
    Warm Regards,
    PavanKumar.G
    Edited by: pavankumar.g on Jan 19, 2012 5:30 AM

Maybe you are looking for