How to switch between different instances of component usage?

Hi All,
Need your help.
My application is about "Program Management", there is a table on the upper level which displays several program header data. in the lower level of the screen, I have a view container in which I embed another component to display program details.For instance,if you make a lead selection on one row of the table above, then the lower part will display the program detail.
Here is the problem: e.g. first, I make a selection on program '001', then I'll create a component usage of the program detail and I put it into a component uage group, second, I make a selection on program '002', then the same like above, I create another component usage and put it into a component usage group. Now I have two instances of program detail component usage, when I select program '001' again, how can I switch back to program '001' detail.
So, I'm trying to achieve multiple instances of program detail so that user don't need to wait for loading program details everytime.
Thanks in advance.
Regards,
Aaron
Edited by: Aaron Shen No.2 on Sep 22, 2009 3:44 AM

Hi Aaron,
As you are using two separate components, they would be having two separate views to display the required information.
In the onleadselect of your main view ( where you are using the individual views of the other components via the viewcontainerUI ), you have to embed the following code:
  DATA lo_api_main TYPE REF TO if_wd_view_controller.
  lo_api_main = wd_this->wd_get_api( ).
  CALL METHOD LO_API_MAIN->FIRE_PLUG
    EXPORTING
     PARAMETERS =
      PLUG_NAME  = 'OP_TO_TWO'
Create two outbound plugs in your window, and link them to the inbound plugs of the individual views of used components.
I am embedding the code of my onleadselection:
method ONACTIONSELECTED .
    DATA lo_nd_table_data TYPE REF TO if_wd_context_node.
    DATA lo_el_table_data TYPE REF TO if_wd_context_element.
    DATA ls_table_data TYPE wd_this->element_table_data.
    DATA lt_table_data TYPE wd_this->elements_table_data.
    data lv_selected_index type i.
  navigate from <CONTEXT> to <TABLE_DATA> via lead selection
    lo_nd_table_data = wd_context->get_child_node( name = wd_this->wdctx_table_data ).
  get element via lead selection
    lo_el_table_data = lo_nd_table_data->get_element(  ).
     CALL METHOD LO_EL_TABLE_DATA->GET_INDEX
       RECEIVING
         MY_INDEX = lv_selected_index
case lv_selected_index.
when 1.
data lo_cmp_usage type ref to if_wd_component_usage.
lo_cmp_usage =   wd_this->wd_cpuse_comp_one( ).
if lo_cmp_usage->has_active_component( ) is initial.
   lo_cmp_usage->create_component( ).
endif.
   DATA lo_api_main TYPE REF TO if_wd_view_controller.
  lo_api_main = wd_this->wd_get_api( ).
  CALL METHOD LO_API_MAIN->FIRE_PLUG
    EXPORTING
     PARAMETERS =
      PLUG_NAME  = 'OP_TO_ONE'
clear lo_cmp_usage.
when 2.
DATA lo_api_main TYPE REF TO if_wd_view_controller.
  lo_api_main = wd_this->wd_get_api( ).
  CALL METHOD LO_API_MAIN->FIRE_PLUG
    EXPORTING
     PARAMETERS =
      PLUG_NAME  = 'OP_TO_TWO'
  data lo_cmp_usage type ref to if_wd_component_usage.
   lo_cmp_usage =   wd_this->wd_cpuse_comp_two( ).
   if lo_cmp_usage->has_active_component( ) is initial.
     lo_cmp_usage->create_component( ).
   endif.
endcase.
endmethod.
Regards,
Prosenjit.

Similar Messages

  • How to switch between different libraries for different iPods?

    Hi,
    I succesfully created two separate iTunes libraries on my computer (windows XP) for the iPods of me and my girlfriend. But, how can we switch easily back and forth between the different libraries?
    The suggested option on http://docs.info.apple.com/article.html?artnum=300432 'method three' and bullet '13' does not appear / work....
    Regards,
    Roy

    thanx for replying so fast.
    No problem, Roy. : - )
    Sorry for the delay in getting back to you this time. : - (
    i'd like to know how i can switch between libraries without closing down iTunes.
    Unfortunately you can only choose your Library at startup. So the only way to switch Libraries is to close iTunes ...
    You might want to let Apple know your thoughts on the matter by submitting this form: http://www.apple.com/feedback/itunesapp.html

  • Script to random switch between different waveforms

    Hello.
    How correctly to write the script for switch between different waveforms during generation?
    For example:
    We are using the niFgen Allocate Named Waveform VI for allocate three Waveforms. When you run Generator, working first Waveforms. Next, the Generator is switched and used in the following only second and third Waveforms.
    Or, we configured 10 Waveforms, and in the process of generating to switch not cyclically between all, but only between 2 and 5 Waveforms.
    Whether it is possible to realize?
    Max O. 
    Engineer and software developer,
    TeSLa.
    Solved!
    Go to Solution.

    Hi Chris,
    Possible that the its scripts and came to use (though I now doubt), but with instruction the if/else/end ifmust be preceded by a generate or wait <N> instruction.
    In this case, if we add generate or wait <N> instructions to this script to get Abra-Cadabra some kind.
    Clarify, what is necessary:
    When starting is not pressed any triggers that generate a waveform0 continuously.
    Further, if we passed to the niFgen Send Software Edge Trigger VI - single the triggerX, begin to generate a waveformX continuously.
    These scripts do not provide the necessary algorithms:
    May be I do not fully understand the scripts work.
    How to ensure continuous generation waveformX by a single sent of the triggerX?
    Please, prompt.
    Regards,  
    Max O.
    Engineer and software developer,
    TeSLa.

  • How to switch between messages in the BlackBerry Hub

    With the release of BlackBerry 10 version 10.1, we’ve added a new gesture to the BlackBerry Hub that allows you to quickly switch between your next and previous messages. It’s simple: while viewing a message drag your finger from the left to the right and in one continuous motion swipe up or down.
    For example, in the following screenshot you’ll notice I am viewing ‘Test 08”. To get to the next message, “Test 09”, all I need to do is swipe from left to right (red arrow) followed by swiping up (green arrow) in a single motion. To switch to the previous message, “Test 07”, I complete the same gesture, but swipe down instead (blue arrow).
    Tip: Using a BlackBerry Q10 or Q5? On top of using this gesture to switch between messages, you also have the option of pressing the N key to view your next message, or the P key to view a previous message.
    If this gesture doesn’t appear to be working on your device, verify you are using BlackBerry 10.1.0.4181 or later by going to Settings > About and reviewing the OS Version field. If the OS Version is lower than 10.1.0.4181, check for updates by going to Settings > Software Updates.
    For more details about the availability of BlackBerry 10.1, check out Inside BlackBerry’s post on BlackBerry 10 Software Updates.
    VIA | helpblog.blackberry.com
    http://helpblog.blackberry.com/2013/10/how-to-switch-between-messages-in-the-blackberry-hub/
    Please thank those who help you by clicking the button.
    If your issue has been solved, please resolve it by marking "Accept as Solution"

    I would set up a variable before you get to that node, lets call it $EmpID and assign to it the value of the prompt you want to play lets say 12345 which would be the library promptID. It will then play prompt, get digits, and once you validate if it goes through the expression that flags it as invalid, in that node re-declare the variable, but this time give it the value of the new prompt you want to play, then sent it back to the node which will then play the new prompt and collect the digits.

  • MSI R9 290 How to switch between Gaming Modes?

    Hi, I just got a MSI R9 290... with Afterburner installed. This card has 3 preset modes that are supposed to be easy to switch between OC Mode 1007Mhz, Gaming 974Mhz, Silent 947Mhz... How do I switch between modes? I just tried to up the MHz in Afterburner and must have done something wrong, becuase I froze everything instalntly and had to reboot. Can someone please advise me how to switch between these modes? Do I have the right software installed, Afterburner or is there another suite specificly for this card? I did not install the card, and sorry I am a noob when it comes to OC. . . Noob to gaming in general, but I am getting some pretty bogus 30FPS on a 2012 game, LA Noire, which shouldnt even be demanding for t

    Quote from: kris.meaney on 07-March-15, 18:45:04
    This card has 3 preset modes that are supposed to be easy to switch between OC Mode 1007Mhz, Gaming 974Mhz, Silent 947Mhz... How do I switch between modes?
    You need the Gaming APP for switching (not Afterburner): http://download.msi.com/uti_exe/gamingApp.zip
    Afterburner is for manual overclocking (for advanced users) if not using the modes.

  • How to switch between markets in AppStore?

    How to switch between markets in AppStore? It says that I cannt buy in Russian market because my account registered in other

    Follow the directions here:
    http://support.apple.com/kb/ht1311

  • Question How to switch between tabs automatically? for example every 30 seconds

    Question
    How to switch between tabs automatically? for example every 30 seconds

    Tab Mix Plus has that feature.
    *Tab Mix Plus: https://addons.mozilla.org/firefox/addon/tab-mix-plus/

  • AS: how to switch between screen modes?

    hi @ all,
    does anybody know how to switch between the 4 screen modes in ps cs3?
    - standard
    - maximized
    - full screen with menubar
    - full screen
    I looked around but could not find anything discribing a way doing this by applescript.
    the only thread I found
    http://www.adobeforums.com/webx/.3bc85cba/0
    refers to javascript but I was not able to adopt it.
    thanks for any help
    Claus

    To do it with AS only, you need to simulate the "f" key with System Events:
    tell application "System Events"
      tell process "Adobe Photoshop CS3" to keystroke "f"
    end tell
    That will loop thought the screen modes as if you did it manually.
    To run the JS from the other thread, you need to use the "do javascript" command. Remember to escape all the quotes in the JS:
    tell application "Adobe Photoshop CS3"
      do javascript "var screenModeOptions = new Array(4);
         screenModeOptions[0] = \"screenModeStandard\";
         screenModeOptions[1] = \"screenModeMaximized\";
         screenModeOptions[2] = \"screenModeFullScreenWithMenubar\";
         screenModeOptions[3] = \"screenModeFullScreen\";
         applyScreenMode(screenModeOptions[0]);
         function applyScreenMode(mode){
          var desc = new ActionDescriptor();
          var ref = new ActionReference();
          var menuID = stringIDToTypeID( mode );
          ref.putEnumerated( charIDToTypeID( \"Mn  \" ), charIDToTypeID( \"MnIt\" ), menuID );
          desc.putReference( charIDToTypeID( \"null\" ), ref) ;
          executeAction( charIDToTypeID( \"slct\" ), desc, DialogModes.NO );
    end tell
    The JS is the better solution if you wanted to skip directly to the desired screen mode without looping through the others.
    Carl.

  • Keyboard switch between different languages

    Does anyone know if the BB10 keyboard will feature an easy switch between different languages that will preserve the anticipation of words used frequently/etc?
    Solved!
    Go to Solution.

    nouaspe wrote:
    That's great - thanks a lot. Is that a basic feature? Is there a list of languages (if one is looking for one with less circulation)?
    yes, it is a basic feature. I frequently switch from French to English and no problem, it is almost magical.
    Languages I have on my Z10 (sorry if I make typos, I have not found a page with the list correctly written)
    Arabic (I don't know which, but it is from right to left)
    Catalan
    Cestina
    Dransk
    Deutch
    Greek
    English UK
    English
    Espanol
    Euskara
    Suomi
    Français
    Galego
    Hebrew
    Hrvatski
    Magyar
    Bahasa Infonesia
    Italiano
    Norsk
    Nederlands
    Portugues (Brasil)
    Portugues (Europeu)
    Polski
    Romana
    Russian
    Svenska
    Thai
    Tiêng Viêt
    Türkçe
    Chinese (simplified)
    Chinese (traditional)
    as you can see:
    Japanese is lacking, because BlackBerry has decided to not sell the Z10 in Japan (they currently have a 0.3 marketshare, the market is mainly dominated by local brand like Sony or Anycall)
    This time, RIM did things right and Arabic & Chinese are available from day 1
    The search box on top-right of this page is your true friend, and the public Knowledge Base too:

  • Switching between different run-time menu programati​cally

    Hi All
     I am planning to build a Bilingual program…….am just doing trial and errors in changing all captions and run-time menu s programmatically with a single button click……….Here my logic is working fine for all captions and graphs also…………..but I could not change the run-time menu……….i am unable to switch between different run-time menus……………
    Here I am sending the program am working on………..please have a look on this, and suggest me something………….hope my problem get resolved.
    Thanks
    Anil Punnam
    Attachments:
    Caption_program.ZIP ‏31 KB

    Hi Anil,
    I'm guessing you're using 7.1?  When I first ran your program in 8.0, it worked perfectly and switched back and forth perfectly.  However, I tried it in 7.1 and saw some bad behavior.  The customer run time menu was not updated in the menu bar.  It looks to me like the run time menu is changing, but the front panel is not updating.  After pressing one of your front panel buttons to change the run-time menu back and forth, if you click on the file menu it should update, although this can lead to some funny looking menus since "affiche" is longer than "file" and you can still see the remnants of the old menu.  Try this and let me know if this is indeed the behavior you are seeing (check out the attached pic).  I thinkt hat R&D already had a report on this, and that is why it is fixed in 8.0.
    Megan B.
    National Instruments
    Attachments:
    RTM.JPG ‏34 KB

  • Context binding between different components using component interface cont

    Please tell me the procedure how to do context mapping between different components ......
    Please post the procedure ASAP.

    Hi Koti,
               Check this
    <a href="/people/bertram.ganz/blog/2007/01/19/new-web-dynpro-java-tutorial--component-interface-definitions-in-practice:///people/bertram.ganz/blog/2007/01/19/new-web-dynpro-java-tutorial--component-interface-definitions-in-practice
    <a href="https://www.sdn.sap.com/irj/sdn/wiki?path=/display/wdjava/usecomponentsinbiggerWebDynproprojects%28componentization%29&">https://www.sdn.sap.com/irj/sdn/wiki?path=/display/wdjava/usecomponentsinbiggerWebDynproprojects%28componentization%29&</a>
    regards
    Sumit

  • How to switch between JRE version dynamically

    hi,
    I have got both jre1.4.1 and jre1.5.0_07 installed on y machine. But i need different version of jre to access two different applications.
    How can i switch between jdk versions.

    Are the JREs being invoked by a browser, if so you can define the preferred version.
    In IE
    <OBJECT classid="clsid:8AD9C840-044E-11D1-B3E9-00805F499D93"
        width="100" height="100" name="anApplet">
        <PARAM NAME="code" VALUE="yourClass.class">
        <PARAM NAME="type" VALUE="application/x-java-applet;version=1.4.1">
        <PARAM NAME="scriptable" VALUE="true">
            No JDK 1.2 support for APPLET!!
    </OBJECT>Substitute type paramter for
    <PARAM NAME="type" VALUE="application/x-java-applet;version=1.5.0">When running a Java 5 applet
    In Firefox
    <object classid="java:yourClass.class"
                  type="application/x-java-applet;version=1.5.0"
                  height="100" width="100" >
    </object>Bamkin

  • How to switch between two query in Web templete.

    Hi all,
      Here i am facing problem to switch between two query in web template by using one 'table' web item. is there any way to use hyperlink 'SAP_BW_URL' and we can switch to query. here i am using these HTML code..
    <table><tr><td class="SAPBEXBtnStdBorder" cellspacing="0" cellpadding="0" border="0"><tr><td>
    <table><tr><td class="sapbexbtnstd" ><A href="<SAP_BW_URL cmd='reset_item' item='table_data' query_ID='ZSD_ZSD_M01_Q20' apply_cmd_on_target= "X">" >Switch to other query</A></td></tr></table>
    but i am not getting correct functionality.
    please help me to solve this problem.
    I know the best way to say thanks in SDN.
    thanks
    Kiran Patel

    Kiran,
      Use the web api reset_data_provider as links or in select option in HTML.
       Onchange event of this select option should call JAVASCRIPT method and
       this in turn resets the current dataprovider to your concerned one.
       How to change graphs:
       The graph item has the default data provider:
       <object>
             <param name="OWNER" value="SAP_BW"/>
             <param name="CMD" value="GET_ITEM"/>
             <param name="NAME" value="CHART_1"/>
             <param name="ITEM_CLASS" value="CL_RSR_WWW_ITEM_CHART"/>
             <param name="DATA_PROVIDER" value="DATAPROVIDER_1"/>
             <param name="TMP_CHART_DATA_HANDLE" value="IIP_49MOXB0UVNOMM6JOZMZU7QO21"/>
             ITEM:            CHART_1
       </object>
      So if you change the DATAPROVIDER_1 using RESET_DATA_PROVIDER to your concerned DP, this changes chart as well !!
       Please use this method and refer to sample code for Onchange Event on SELECT OPTION:
      <HTML>
    <HEAD>
    <script>
    function callDP() {
         if(document.forms[0].dp.value == "1") {
            //form your URL here..
           url = SAP_BW_URL_Get() + "&CMD=RESET_DATA_PROVIDER&DATA_PROVIDER_1=..&...";
            SAPBWOpenURL(url);
            //or docuemtn.location.href = url..
            //etc..
    </script>
    </HEAD>
    <BODY>
    <form>
    <select name="dp" onChange="javascript:callDP();">
    <option value="1">1</option>
    <option value="2">2</option>
    </select>
    </form>
    </BODY>
    </HTML>
    HOPE THIS HELPS !!!

  • How to switch between apps in mission control shortcut key

    I open two apps in my macbook, how can i select the app without clicking on it?.I know that f3 > mission control and then click, but i want to switch between apps with keyboard shortcut.Thanks in advance for your help.( I am runnig lion).

    Hold down the cmd (⌘) key and briefly press the tab key (⇥) then use the left/right arrow keys to select the application you wish to switch to.  When done release the cmd key.

  • How to switch between 2 windows of the same application using Cmd+Tab

    Hi,
    I am using my mac now since about 10 months. I was used to work with Linux and Windows XP.
    Something I am badly missing on mac os x is the possibility to switch between 2 windows of the same application using cmd + tab just like it simply works for Linux and Windows (and maybe many other OS out there!).
    Very often I have 2 text files open in 2 editor windows (e.g. TextEdit) and need to copy and paste text from one window to the other. I was used to simply use ALT+TAB. But here I have to get my right hand away from the keyboard and use the mouse to change the focus from one window to the other and then use the mouse again to get the focus back to the previous TextEdit windows.
    THIS REALLY *****!!!! It makes me crazy. I cannot believe that such a "modern" OP does not support this action. I must be doing something completely wrong or did not understand the mac correctly. Right?
    Does anyone have an idea how I can get mac to do something all other operating systems so easily do?
    Thanks
    Quartz84

    Hi Kappy,
    well what you are saying is obvious to me. This is not the point for me and not what I wanted to know. But I think you answered my question anyway: OS X is unable to switch between windows of the same application as I mentioned in my example.
    WHY NOT???
    Every other OS is able to differentiate between windows and not just applications.
    Another example: The Mail application and an Email editor window. When you are writing an Email and you want to switch to the main window of the Mail application to read something you must again use the mouse!
    I mean Apple seems to be "somehow" using FreeBSD in the background and even in FreeBSD's window manager it is possible to switch between windows of the same application.
    Well, in the Apple world it is always the pour user who is not intelligent enough to understand Apple's philosophy ;-(
    To me this is not modern, it is simply a weakness of the OS.
    Cheers
    Quartz84

Maybe you are looking for