Create multiple elements dynamically at one time

Hi,
I need to create some links dynamically.
Below is my code... but I need to know instead of multiple steps.. is there a way to create dynamic elements together using one method itself....  or once i create the elements can i embed all these links together in the view?
  lr_lta = cl_wd_link_to_action=>new_link_to_action(
  id = 'LNK_CREATE'
  on_action = 'ON_NAVIGATE'
  text = 'Create'
  view = lr_view ).
  cl_wd_matrix_data=>new_matrix_data( element = lr_lta ).
  lr_container->add_child( the_child = lr_lta ).
  lr_lta = cl_wd_link_to_action=>new_link_to_action(
  id = 'LNK_HISTORY'
  on_action = 'ON_NAVIGATE'
  text = 'Hitory'
  view = lr_view ).
  cl_wd_matrix_data=>new_matrix_data( element = lr_lta ).
  lr_container->add_child( the_child = lr_lta ).
Any help will be grateful.
Regards and Thanks
Tenzin

Hi,
This is a sample code for doing it using loop.
I just refined the code to make it most amenable to your requirement.
The code gives two different links at the same time with two different actions.
method WDDOMODIFYVIEW .
IF first_time eq abap_true.
data lr_ref type ref to cl_wd_link_to_action.
data lr_cont_ref type ref to cl_wd_uielement_container.
data lr_layo_ref type ref to cl_wd_flow_data.
data lv_times type i value 2.
data lv_count type i value 1.
lr_cont_ref ?= view->get_element( 'ROOTUIELEMENTCONTAINER' ).
do lv_times times. "decide how many times you want the link
case lv_count.     "decide what link to action with what action should be defined
when 1.
CALL METHOD cl_wd_link_to_action=>new_link_to_action
   EXPORTING
     enabled             = ABAP_TRUE
     image_first         = ABAP_TRUE
     on_action           = 'First_Action'
     text                = 'First Link' "to display 'Gangtok' when clicked
   receiving
     control             = lr_ref
   CALL METHOD cl_wd_flow_data=>new_flow_data
   EXPORTING
     element                = lr_ref
   receiving
     control                = lr_layo_ref
CALL METHOD lr_cont_ref->add_child
  EXPORTING
    index     = 1   "this is to set link to action in first place
    the_child = lr_ref
When 2.
  CALL METHOD cl_wd_link_to_action=>new_link_to_action
   EXPORTING
     enabled             = ABAP_TRUE
     image_first         = ABAP_TRUE
     on_action           = 'Second_Action' "to display 'Kolkata' when clicked
     text                = 'Second Link'
   receiving
     control             = lr_ref
  CALL METHOD cl_wd_flow_data=>new_flow_data
   EXPORTING
     element                = lr_ref
   receiving
     control                = lr_layo_ref
CALL METHOD lr_cont_ref->add_child
  EXPORTING
    index     = 2   "this is to set the link to action in 2nd place
    the_child = lr_ref
endcase.
lv_count = lv_count + 1.
enddo.
endif.
endmethod.
Regards,
Prosenjit.
Edited by: prosenjit chaudhuri on Feb 16, 2009 12:48 PM

Similar Messages

  • How create multiple named folders at one time? 10.10.02

    How create multiple named folders at one time? 10.10.02
    Hello all,
    I need to create 208 named folders at one time. Please advise.
    Thanks!

    You may want to ask this in the Yosemite forum. This is the Mavericks forum.

  • Can we create multiple admin servers in one one weblogic domain.

    Hi All,
    Can we create multiple admin servers in one one weblogic domain.
    if yes, please let me know.
    Thanks

    http://download.oracle.com/docs/cd/E21764_01/web.1111/e13716/toc.htm
    Not through the configuration wizard.
    To handle admin server availability (the admin server is not clusterable). This means that if the admin server goes
    down, you cannot administer your WebLogic Server domain until you bring it back up. In most cases, you may
    not be too concerned if the admin server goes down because all you need to do is restart it. If you use the node
    manager to start the admin server, the node manager can automatically restart a failed admin server just like it can any other server.
    What happens if the machine where the admin server runs fails in such a way that you cannot restart the admin server?
    The answer is simple if you prepare for this event. Proper operation of the admin server relies on several configuration files
    and any application files it controls. Typically, the best thing to do is to store the admin server's directory tree on a shared disk.
    As long as the configuration and application files are accessible, you can restart the admin server on another machine. It is up
    to you to make sure that you don't have more than one admin server running at a time. If the new machine can assume the
    original admin server's Listen Address (or if it was not set), you can simply start the admin server on the new machine without
    any configuration changes.
    Otherwise, you will need to change the admin server's Listen Address. Since the managed servers ping the admin server URL every
    10 seconds until it comes back up, you need to devise a way for the admin server URL to allow the managed server to find the restarted
    admin server on the new IP address. The easiest way to achieve that is using a DNS name that maps to both IP addresses, or better yet
    that is dynamically updated to point to the correct location of the admin server. If this is a graceful shutdown and migration, use the
    WebLogic Console to change the Listen Address just before shutting down the admin server. If not, you will need to edit the config.xml
    file by hand to replace the old Listen Address with the new one. Typically, it is recommended to plan ahead so that everything you need is
    already in place to make admin server failover as painless as possible.

  • Replace audio in multiple video clips at one time

    Hello. I am new to the forum so I apologize if I break any of the rules!
    I have a collection of tutorial videos, all edited but the audio had some balance issues. The files were not in Premiere Pro at the time. They are the final edited videos but then I was told the audio needed to be adjusted. 
    I have re-balanced the audio, saved the audio as wav files and now I need to replace the old audio (in the finished video file) with the new audio (the wav files I edited and saved). The timing is all the same. It's just a matter of replacing the current file.
    Is this doable as a batch process? Is it doable in Premiere Pro or do I need to use Audition or some other Adobe software?
    I hope this makes sense.
    Thank you in advance!
    Alan Read
    SC, USA

    hello ,thanks for jour mail ,but my English is very very bad sorry but
    many thank for your feedback. Hav a nice Day
    Am 09.12.2014 16:57, schrieb carpmusic:
    >
          Replace audio in multiple video clips at one time
    created by carpmusic <https://forums.adobe.com/people/carpmusic> in
    /Premiere Pro/ - View the full discussion
    <https://forums.adobe.com/message/6998981#6998981>

  • In Pages (5.5.1) can I create multiple Paragraph Styles within one paragraph?

    In Pages (5.5.1) can I create multiple Paragraph Styles within one paragraph. 
    I need to make a table of contents for my Mater's Thesis and want to use the automatic table of contents feature.  I want the first sentence of a paragraph to have a different paragraph setting than the rest of the paragraph.  Is this possible?
    Thanks!

    Nice of you to be doing this for your Mother's Thesis.
    There are several issues here:
    1. A Paragraph Style is what it says, the style for the paragraph
    2. You can format text within a paragraph by applying a Character Style
    3. Pages 5.5.1 lets you apply formatting to overall text for the T.O.C. but not parts of it and you can not retain that formatting as a Paragraph style
    So in answer to your question, no.
    You will need to create the T.O.C. manually and unfortunately as Pages 5.5.1 can't create bookmarks (just one of over 100 missing features) you will be unable to link the T.O.C. to the referred pages in the list.
    Peter
    Apple's marketing slogan:
    Pages 5.5.1 - Can't Do That!

  • Is there a way to create multiple BQY output to one of the Job File ?

    Hello,
    I am using EPM11.1.2.3.501 version.
    BQY report due to the large amount of data, it is difficult to use a WebClient.
    So will share on a quarterly basis.
    However,
    If modifications are to occur,There are difficulties must modify each file.
    For example,
    Register 2014 1Q, 2014 2Q, 2014 3Q, 2014 4Q BQY Job file.
    When you run the job, the output of the job file is created.
    If the job file is changed, you must modify all four files.
    This will be only grow ations.
    Is there a way to create multiple BQY output to one of the Job File ??
    Please help me.
    Thanks

    It is not possible to have multiple BQY outpu into a job file.
    Thanks,
    KK

  • How do you remove multiple email messages at one time

    I have a iphone 4 and today it started piling up over 4000 undeliverable messages for no apparent reason. I somehow managed to stop the process but I am left with over 4000 messages that I need to delete. How do you remove multiple email messages at one time. I can "mark" all the messages at once but I cannot find the move or delete button to trash the messages. Can some one help me out.
    Thanking you in advance.
    PL

    Just figured it out - I can select multiple messages as you suggested when I am not in full screen mode.
    So once I come out of full screen mode - then the multiple windows open.
    QED

  • How can we take backup of all the RDL'S existing at Report server dynamically at one time

    How can we take backup of all the RDL'S existing at Report server dynamically at one time ? I want to take backup of all the reports existing at the report server dynamically at one time only. currently I'm able to take backup of the reports folder wise
    using VBScript. and I have to pass the folder names again and again. I want this to be happened for all the reports of all the folders at single shot only using VBScript.

    Hi DineshRemash,
    Based on my research, we can store the following VB Script to a text file, then modify the file name extension from .txt to .rss.
    Dim rootPath As String = "C:\Reports"
    Sub Main()
    Dim items As CatalogItem() = _
    rs.ListChildren("/", true)
    For Each item As CatalogItem in items
    If item.Type = ItemTypeEnum.Folder Then
    CreateDirectory(item.Path)
    Else If item.Type = ItemTypeEnum.Report Then
    SaveReport(item.Path)
    End If
    Next
    End Sub
    Sub CreateDirectory(path As String)
    path = GetLocalPath(path)
    System.IO.Directory.CreateDirectory(path)
    End Sub
    Sub SaveReport(reportName As String)
    Dim reportDefinition As Byte()
    Dim document As New System.Xml.XmlDocument()
    reportDefinition = rs.GetReportDefinition(reportName)
    Dim stream As New MemoryStream(reportDefinition)
    document.Load(stream)
    document.Save(GetLocalPath(reportName) + ".rdl")
    End Sub
    Function GetLocalPath(rsPath As String) As String
    Return rootPath + rsPath.Replace("/", "\")
    End Function
    Then navigate to the folder contains the script, we can directly run the below command from the run menu:
    rs -s
    http://aa/ ReportServer -i download.rss
    We can modify the rootpath to point at whaterver fold you’d like to download the RDL files.
    Hope this helps.
    Thanks,
    Katherine Xiong
    Katherine Xiong
    TechNet Community Support

  • Creating multiple http servers on one machine

    I created multiple http servers on one machine.
    I did this in the following way:
    Created a http service as nt service with the following command:
    apache -i -n Testservice -f d:\oracle\isuites\apache\apache\conf\httpd2.conf.
    When I start the service, I always get an error:
    Didn't return an error. Cannot start service.
    Can someone help me.
    I need two httpd services as nt service. Because, I want to use oracle fail safe. So I need a service.
    Alternative : I can create batch files. But I want to start these batch files as nt service. Is there a possibility on
    Windows nt to do this, or an available tool.
    Thanks in advance,
    Iloon

              "Jason Rosenberg" <[email protected]> wrote:
              >Hello,
              >
              >I am wondering about having multiple servers on one machine.
              >I take it, each server will require a unique ip address, which can
              >be done either by using multiple NIC's or using multi-homing.
              If you want to have multiplie servers in the same machine and you want to cluster them then you need ip for each instance.
              If you want multiple instances without clustering, then you can have them run on the same ip but each one should have a different port.
              >
              >I am asking because I am wondering whether it will always be valid
              >for me in servlet code to identify my current server instance by
              >ip address (InetAddress). Or is there a better way to do this?
              If you are accessing the ejb/services on the same server using a servlet. You can get the context, simply using the default getInitialContext(). This should return the context to the local machine. This shoudnt require any ip information.
              >
              >Jason
              >
              >
              

  • Is there a way to put fades on multiple audio regions at one time?

    is there a way to put in and out fades on multiple audio regions at one time?
    thanks!
    Luke.

    absolutely brilliant!
    you just saved me a lot of time.
    thank you!!
    Luke.

  • How to uninstall multiple cloud apps at one time?

    How do I uninstall multiple cloud apps at one time from windows 7 pro?

    Hi Bigdog3766,
    Please refer to the below mentioned link under "Uninstall Apps":
    http://helpx.adobe.com/creative-cloud/help/install-apps.html
    Let us know if it helps,
    Thanks!
    Gurleen

  • Change multiple object properties at one time

    I'm using Universal Designer and I have to manually change the properties of over 100 objects.  Does anyone know how I can change multiple object properties at one time?

    Hi,
    This links may be helpful to you,
    http://forumtopics.org/busobj/viewtopic.php?t=94828&sid=1eb4a78e88c26b14418c354d1321e350
    http://www.forumtopics.com/busobj/viewtopic.php?t=21029
    All the Best,
    Madhu...

  • Sending multiple request approval at one time

    Hi,
    Im working on a senario thats sending multiple request approvel at one time with HWC application. For example , client approves one request and it approves multiple requests at one time as well. Is it possible make this with HWC ?
    Thanks in advance.

    If you have a list key, it'll have child MessageValueCollection keys (specifically, the value of that list key will be an array of MessageValueCollection objects). Each MessageValueCollection has a state, "add", "update", "delete" or empty. By specifying mappings between list key actions and MBO operations, or by doing so manually in the WorkflowClient.xml, you can specify which MBO operation will be invoked for each "add" MessageValueCollection, which MBO operation will be invoked for each "update" MessageValueCollection and each "delete" MessageValueCollection when the message is submitted to the server via an Online Request or Submit Workflow, where it will loop through the MessageValueCollections and execute the appropriate MBO operation for each.
    In the tooling, you can do this by having a listview bound to that list key and having subsequent screens that invoke Add/Update/Delete List Key Collection menuitems.  In that scenario, when you update the rows in the listview, the effects don't occur immediately, but rather wait until you submit them as a batched operation, which will behave as described above.

  • Problem while creating multiple tabs dynamically webdynpro abap

    Hi Experts,
    i am trying to create multiple tabs in tabstrip dynamically but the tabs are hiding behind one other..
    Let me know how to fix this.
    Thanks
    Abdul Hakim

    Are you expecting from expert only?Sorry I am not a expert, 
    About issue:...
    I think number of tabs will display that depends on the width of the container.. As of now how many tabs you have and hw many displaying at a time...
    Please increase width ofyour container and check  and let me know.
    Its just a try not a solution.
    Regards
    `srinivas

  • Creating multiple scroling text on one pane

    yeah i have been working on this banner im making and i absolutly dislike GUI i have most of the core programing but im having trouble with the GUI
    i have been using test strings so here is the panel class i have been working on
    trying to create multiple scroling text with multiple timers (iknow the timeings off but thats not the problem)
    the program should send one string scroling across the panel than the next based on timers but i dont understand how to do that exactly
    i understand why its not working but i need some nudges in the right direction to get how to do it
    import java.awt.*;
    import java.awt.event.*;
    import javax.swing.*;
    public class stockTickerGUI extends JPanel
        private int xCord = 0;
        private int yCord = 20;
        private int secondXCord = 20;
        private String message = "";
        private String [] messageList;
        protected int counter = 0;
        private int width;
        public stockTickerGUI(String [] listOfStocks)
         messageList = listOfStocks;
         message += listOfStocks[counter];
         Timer timer = new Timer(100, new TimerListener()); //timer for movement
         Timer timer2 = new Timer(100, new TimerListener());
         timer2.setInitialDelay(150);
         Timer timer3 = new Timer(100, new TimerListener());
         timer3.setInitialDelay(200);
         Timer timer4 = new Timer(100, new TimerListener());
         timer.start();
        protected void paintComponent(Graphics x)
         super.paintComponent(x);
         if(xCord > getWidth())
          xCord = -20;
         xCord += 5;
         x.drawString(message, xCord, yCord);
        class TimerListener implements ActionListener
         public void actionPerformed(ActionEvent x)
          repaint();
          counter++;
          if(counter >= messageList.length)
           counter = 0;
          message = messageList[counter];
    }

    could you go in to some more detail heres what i have so far from what you said
    i tryed setting the layout of the label's to null (not showen here) but nothing happened and i keep getting an nullpointexecption
    import java.awt.*;
    import java.awt.event.*;
    import javax.swing.*;
    public class stockTickerGUI extends JPanel
            private int xCord = 0;
        private int yCord = 20;
        private int secondXCord = 20;
        private String message = "";
    //    private String [] messageList;
        protected int counter = 0;
        private int width;
        protected JLabel [] labelList;
        public stockTickerGUI(String [] listOfStocks)
    //         messageList = listOfStocks;
             message += listOfStocks[counter];
             labelList = new JLabel[listOfStocks.length];
             for(int i = 0; i < listOfStocks.length; i++)
                  labelList.setText(listOfStocks[i]);
              labelList[i].setHorizontalTextPosition(xCord - (5 * i));
         Timer timer = new Timer(100, new TimerListener()); //timer for movement
         timer.start();
    class TimerListener implements ActionListener
         public void actionPerformed(ActionEvent x)
                   if(xCord > getWidth())
                        xCord = -20;
                   xCord += 5;
                   for(int i = 0; i < labelList.length; i++)
                        labelList[i].setHorizontalTextPosition(xCord);

Maybe you are looking for

  • WebDynpro ABAP integrated into the NetWeaver Portal - One for Mr Jung :)

    Hi <h2>Introduction</h2> I've developed a WebDynpro Component that uses 8 other components. The initial component has 1 view with a PhaseIndicator element with 8 phases. Selecting a phase pops up a window of the appropriate components used as usage c

  • Save spot colours in Photoshop for import to Indesign

    I'm having problems in Indesign due to using drop shadows in some graphics which are over an image with transparencies. What I think would solve the problem is to remove the transparencies in the image using photoshop and then use that. However, the

  • Moving downloads to a new PC

    I have purchased Adobe Professional for another PC, unfortunately that PC has died and I want to get Adobe on to this PC, any ideas?

  • Has anyone else seen this dialog box graphical phenomenon?

    Hi, I'm running 10.5.4 on a MacBook Pro (4,1) and have noticed a strange effect on some dialog boxes in Leopard - darker grey blocks appear around text, controls and buttons within the dialog box. The effect occurs on both the MacBook Pro display and

  • New PC Build

    Hi, I'm looking for a desktop PC that will happily run the Adobe CC suite. I typically have Photoshop, Lightroom, Bridge and Dreamweaver all open at the same time, along with Firefox and Outlook. Other requirements include the ability to use a 4K mon