How to add several lines to the CreateWithParameters method

Hello
can someone tell me how to insert several rows in a table by using the CreateWithParameters method, which I use in a taskflow.

That's why you get a null pointer...
Add the iterator in this page or call the method in the second page... both should work... :)

Tags: Java

Similar Questions

  • How to add multiple lines when the button is clicked

    How to add multiple lines when the click on button now is just add a row .plz give me idea how... waiting for answer

    / public final class screen extends MyScreen
    {
    /**
    * Creates a new object of MyScreen
    */
    ObjectChoiceField obj1 obj2, obj3, obj4.
    Table of String() = {'101 ', ' 102'};
    String of shadow [] = {"Shade1", "Shade2"};
    Rolls of string [] = {'101 ', ' 102'};
    String cutting [] = {"100-150", "150-200"};
    Chain of selectedindex1, selectedindex2, selectedindex3, selectedindex4;
    LabelField lbl1 lbl2, lbl3, lbl4;
        
    GFM LinedGridFieldManager;
    HFM HorizontalFieldManager, hfm1, hfm2 hfm3;
    VerticalFieldManager vfmMain;
        
    public MyScreen()
    {
        
    Set the displayed title of the screen
    hfm1 = new HorizontalFieldManager (HorizontalFieldManager.NO_VERTICAL_SCROLL |) HorizontalFieldManager.NO_VERTICAL_SCROLLBAR);
    hfm2 = new HorizontalFieldManager (HorizontalFieldManager.NO_VERTICAL_SCROLL |) HorizontalFieldManager.NO_VERTICAL_SCROLLBAR);
    hfm3 = new HorizontalFieldManager (HorizontalFieldManager.NO_VERTICAL_SCROLL |) HorizontalFieldManager.NO_VERTICAL_SCROLLBAR);
    HFM = new HorizontalFieldManager (HorizontalFieldManager.FIELD_RIGHT);
    vfmMain = new VerticalFieldManager (Manager.NO_VERTICAL_SCROLL |) Manager.NO_HORIZONTAL_SCROLLBAR);
            
    obj1 = new ObjectChoiceField ("", graph, 0, FIELD_LEFT);
    obj2 = new ObjectChoiceField ("", blind, 0, FIELD_LEFT);
    Obj3 = new ObjectChoiceField ("", rolls, 0, FIELD_LEFT);
    Obj4 = new ObjectChoiceField ("", cuts, 0, FIELD_LEFT);
            
    LBL1 = new LabelField("");
    LBL2 = new LabelField("");
    lbl3 = new LabelField("");
    lbl4 = new LabelField("");
            
    ButtonField btnAdd = new ButtonField ("ADD", FIELD_RIGHT);
            
    GFM = new LinedGridFieldManager (4, LinedGridFieldManager.VERTICAL_SCROLL);
            
    hfm1.setMargin (20, 0, 10, 0);
    hfm1. Add (new LabelField ("Chart"));
    hfm1. Add (obj1);
    hfm1. Add (new LabelField ("Shade"));
    hfm1. Add (obj2);
            
    hfm2. Add (new LabelField ("Rolls"));
    hfm2. Add (Obj3);
    hfm2. Add (new LabelField ("Cuts"));
    hfm2. Add (Obj4);
    HFM. Add (btnAdd);
            
    GFM. Add (new LabelField ("Chart"));
    GFM. Add (new LabelField ("Shade"));
    GFM. Add (new LabelField ("Rolls"));
    GFM. Add (new LabelField ("Cuts"));
            
    vfmMain.add (hfm1);
    vfmMain.add (hfm2);
    vfmMain.add (hfm3);
    vfmMain.add (hfm);
    vfmMain.add (new SeparatorField());
    vfmMain.add (gfm);
    Add (vfmMain);
            
    btnAdd.setChangeListener (new FieldChangeListener()
    {
    ' Public Sub fieldChanged (field field, int context) {}
    TODO self-generating method stub
    selectedindex1 = chart [obj1.getSelectedIndex ()];
    selectedindex2 = shade [obj2.getSelectedIndex ()];
    selectedindex3 = rolls [obj3.getSelectedIndex ()];
    selectedindex4 = cuts [obj4.getSelectedIndex ()];
                    
    While (LBL1. GetText(). Equals("") | LBL2. GetText(). Equals("") | lbl3. GetText(). Equals("") | lbl4. GetText(). Equals(""))
    {
    LBL1. SetText (selectedindex1);
    LBL2. SetText (selectedindex2);
    lbl3. SetText (selectedindex3);
    lbl4. SetText (selectedindex4);
                    
    GFM. Add (LBL1);
    GFM. Add (LBL2);
    GFM. Add (lbl3);
    GFM. Add (lbl4);
                    
    }
    }
    });
    }
    }

    Hi Piya,

    I run your code, and according to your logic that it works correctly.

    It's adding that line only once because according to your logic that one line can be added to MDT, if you do not want to add line on each click on the button, follow these steps:

    selectedindex1 = chart [obj1.getSelectedIndex ()];
    selectedindex2 = shade [obj2.getSelectedIndex ()];
    selectedindex3 = rolls [obj3.getSelectedIndex ()];
    selectedindex4 = cuts [obj4.getSelectedIndex ()];

    Lbl1 LabelField = new LabelField("");
    Lbl2 LabelField = new LabelField("");
    LabelField lbl3 = new LabelField("");
    LabelField lbl4 = new LabelField("");
    If (LBL1. GetText(). Equals("") | LBL2. GetText(). Equals("") | lbl3. GetText(). Equals("") | lbl4. GetText(). Equals(""))
    {
    LBL1. SetText (selectedindex1);
    LBL2. SetText (selectedindex2);
    lbl3. SetText (selectedindex3);
    lbl4. SetText (selectedindex4);
                    
    GFM. Add (LBL1);
    GFM. Add (LBL2);
    GFM. Add (lbl3);
    GFM. Add (lbl4);
                    
    }

  • How to add two lines when the second row is not visible, but also gets the first data line too?

    Mr President

    Jdev worm is 12.2.1

    How to add two lines when the second row is not visible, but also gets the first data line too?

    I want to add two lines like below picture, but want the second to remain invisible.

    tworows.png

    I asked this question but my way of asking was wrong, that's why for me once again.

    Concerning

    Try to follow these steps:

    1. in the database table to add the new column "JOIN_COLUMN" and add the new sequence "JOIN_SEQ".

    2. Add this new column in the entity object. (You can add this in entity object by right clicking on the entity object and then select "Synchronize with database" then the new column and press on sync)

    3. in your bookmark create button to create only one line NOT 2 rows.

    4 - Open the object entity--> java--> java class--> on the entity object class generate and Tick tick on the accessors and methods of data manipulation

    5 - Open the generated class to EntityImpl and go to the doDML method and write this code

      protected void doDML(int operation, TransactionEvent e)
      {
        if(operation == DML_INSERT)
        {
          SequenceImpl seq = new SequenceImpl("JOIN_SEQ", getDBTransaction());
          oracle.jbo.domain.Number seqValue = seq.getSequenceNumber();
          setJoinColumn(seqValue);
          insertSecondRowInDatabase(getAttribute1(), getAttribute2(), getAttribute3(), getJoinColumn());
        }
    
        if(operation == DML_UPDATE)
        {
          updateSecondRowInDatabase(getAttribute1(), getAttribute2(), getAttribute3(), getJoinColumn());
        }
    
        super.doDML(operation, e);
      }
    
      private void insertSecondRowInDatabase(Object value1, Object value2, Object value3, Object joinColumn)
      {
        PreparedStatement stat = null;
        try
        {
          String sql = "Insert into table_name (COLUMN_1,COLUMN_2,COLUMN_3,JOIN_COLUMN, HIDDEN_COLUMN) values ('" + value1 + "','" + value2 + "','" + value3 + "','" + joinColumn + "', 1)";
          stat = getDBTransaction().createPreparedStatement(sql, 1);
          stat.executeUpdate();
        }
        catch (Exception e)
        {
          e.printStackTrace();
        }
        finally
        {
          try
          {
            stat.close();
          }
          catch (Exception e)
          {
            e.printStackTrace();
          }
        }
      }
    
      private void updateSecondRowInDatabase(Object value1, Object value2, Object value3, Object joinColumn)
      {
        PreparedStatement stat = null;
        try
        {
          String sql = "update table_name set column_1='" + value1 + "', column_2='" + value2 + "', column_3='" + value3 + "' where JOIN_COLUMN='" + joinColumn + "'";
          stat = getDBTransaction().createPreparedStatement(sql, 1);
          stat.executeUpdate();
        }
        catch (Exception e)
        {
          e.printStackTrace();
        }
        finally
        {
          try
          {
            stat.close();
          }
          catch (Exception e)
          {
            e.printStackTrace();
          }
        }
      }
    
  • How to delete several lines in the details Table with PRIMARY KEY = ("VID", "LINEITEM")?

    Mr President

    My worm Jdev is 12.2.1.

    I have master tables / details.

    I have 2 lines for each PRIMARY KEY = ("VID", "LINEITEM") as below in the Details table.

    delete.png

    Please help how to get a button on a jsf page to remove these two lines at a time.

    Concerning

    So, in your app (data model) module, you have a master relationship / typical retail:

    And the relationship between them is based on some ViewLink

    Now go to the ViewLink, relationship, accessor.

    Take a look at the Destination accessor.

    Generate accessor object to check and give a name Acessor

    Then go to the master VO, Java and Include accessor, the class generate a display line:

    Go to the class view Java generated line, you'll find a method with the name of the accessor of the previous step, in the form of:

    public RowIterator getYourDetails...or_whaterever_IsAccessorName..() {
    }
    

    Now, in the same Java class, write the following Java method:

    public void removeDetails(){
      RowIterator details = getYourDetails...or_whaterever_IsAccessorName..(); // it is RowIterator over all details
      Row r = details.first();
      while (r != null) {
          r.remove();
          r = details.next();
      }
    }
    

    This method on the Cilent export line Interface:

    Finally, pass the data controls and drop this operation on the form as a button...

  • How to add new features to the line in the nested table advace?

    Hello

    I want to create a new line in the nested table advance.

    Help, please.

    Thank you

    Hello

    Use the code below to add a line in the nested Table.

    If (PageContext.GetParameter ("addRows")! = null) {}

    OAAdvancedTableBean sectionsTable = (OAAdvancedTableBean) webBean.findChildRecursive ("AdvTblRN");

    OAInnerDataObjectEnumerator sectionsEnum = new OAInnerDataObjectEnumerator (pageContext, sectionsTable);

    {while (sectionsEnum.hasMoreElements ())}

    Set of rows sectionsRowSet = sectionsEnum.nextElement () (set of lines);

    for (int i = 0; i)< 1;="">

    NewRow = sectionsRowSet.createRow ((OARow)) OARow;

    sectionsRowSet.insertRowAtRangeIndex (sectionsRowSet.getRowCount (), newRow);

    }

    }

    Thank you

    Dilip

  • Add several lines in tabular form which object to list different shows to all rows

    Hello

    Apex 4.2, oracle 11 g 2

    I have a table on the emp table where when I click on Add button line

    then I get no lines that are stored in the string.

    for this element of the page creation PX_job that return the value of separate employment with two points separate values by the

    for example seller: Analyst: Clerk: Manager: President

    to add several lines to add lines.

    by using the dynamic action

    event: click on

    selection type: button

    Action: run javascript code

    as follows

    var a = $v("PX_job").split(":") // Delimiter is a string
    for (var i = 0; i < a.length; i++)
    {
    
    apex.widget.tabular.addRow();
    
    }
    
    

    This work that well it adds the number ranks equal to 5

    now I'm post job as select list

    now I want to display the list of work in form of tables as row 1 poster list entry, second row entry list second poster... last line shows last entry from list

    but working this column in all the rows by first writing list of projects in the work list

    How to solve this problem.

    Leave.

    Hi, go,

    Yes, you need to replace "myvalue" with the return value of the select list. But even in this case it would be a problem because it would change all the lines.

    In any case, I changed the code to do this:

    apex.widget.tabular.addRow (); Add the line

    var checkboxIndex is apex.jQuery('input[name=f01][value=0]').eq (i) .parent () .parent () .index ();. get the number of the line that was added

    var SelectItem = apex.jQuery('select[name=f04]').eq (checkboxIndex); Use this number to get the selection list

    iOption var = apex.jQuery (SelectItem) .children () .eq (i) .val (); Get the i option value

    apex.jQuery (SelectItem) .val (iOption); Set the value of the option

    I hope it's clear.

    Kind regards

    Joni

  • How to add 2 points on the Noel e? I don't have a 2nd series of digits to the right of the keyboard.

    How to add 2 points on the letter e in the Noel case?  I don't have the 2nd series of digits to the right of the keyboard. Windows 8

    Wednesday, April 23, 2014 23:25:53 + 0000, RobertNortonWZ wrote:

    How to add 2 points on the letter e in the Noel case?  I don't have the 2nd series of digits to the right of the keyboard. Windows 8

    You mean you want the e character? These two points are called a
    umlaut. You do not add points; the e with points is another
    a simple e character. There are several ways to get this
    character, but a simple is to hold the ALT key and type 137.

    As a point of information if you are interested, the subject of a
    umlaut is to indicate that the second of the two successive vowels is
    pronounced separately. So the word 'book' is pronounced buk, but the
    Book name is pronounced BO - ock.

  • How to add an outline to the text?

    How to add an outline to the text?

    Add a line in the character of the text layer settings.

  • Question: how to format multiple lines in the Guild: email field

    Hello

    I would like to have a message of several lines in the body of the email. I can get the text to include, but all in a single line. How can I get the lines to be separated into several separate lines? Everything except the formatting of the message works very well. Here's my script, which does not work:

    app.mailMsg ({}

    bUI: false,

    cTo:

              cCc: " includedaccounting@fheg. Follett.com ; ", "

    bassujetti: 'True full up' + "" + page1.storeInfo.arMajor.rawValue + "" + pages1_3.page1.storeInfo.storeNum.rawValue,.

    CMSG: 'Hello,';

    + 'The true for this store was completed. Please find the links to the list control and reconciliation below. \n » ;

    + "Checklist: \n";

    + ' Reconciliation: \n ";

    + "Thank you, \n";

    }}}}});

    Thank you

    MDawn

    Hello

    It seems that you may have a few errors of syntax... or is the forum scrap things up.  You do not want any semicolons in the argument mailMsg() and you used all the accolades.  Something like;

    app.mailMsg ({}

    bUI: false,

    cTo:

    cCc: "[email protected];"

    bassujetti: 'True full up' + "" + page1.storeInfo.arMajor.rawValue + "" + pages1_3.page1.storeInfo.storeNum.rawValue,.

    CMSG: 'Hello '

    + 'The true for this store was completed. Please find the links to the list control and reconciliation below. \n ".

    + "Checklist: \n".

    + ' Reconciliation: \n ".

    + "Thank you, \n".

    });

    Concerning

    Bruce

  • How to animate a line with the pen tool to give the impression that it is plotted?

    How to animate a line with the pen tool to give the impression that it is plotted?

    Or you can choose the pen tool (g), set the padding to zero and the race to what you want, then draw a path, then press U twice to reveal all of the properties that have been changed for the layer, and then click Add (top-right) and select Connect the tracks.

    To make the race work just animate the start or end point and sent to paint on original or reveal original or normal.

  • How do a straight line of the curve?

    Hello

    I wonder how to move a line to the right a little bit without erasing anything.  How can I move on a bit?  The area that surrounds it may curve a little with it.

    Thank you

    Looks like you could had to use liquefy to move the line, or deformation of the puppet or perspective distortion. Several ways to edit an image and it is difficult to say without seeing a screen shot.

  • Add a line to the table programmatically

    Hello

    How do I add lines to the af: table of the java class? for that to editable object view exist on the JSPX page

    Thank you

    Chaya

    You can see the following code to add a line at the end of the table programmatically:

    public String cb1_action() {}

    Add the code in the event here...

    BindingContainer bc is BindingContext.getCurrent () .getCurrentBindingsEntry ();.

    JUCtrlHierBinding hierBinding = (JUCtrlHierBinding) bc.get ("EmployeesView3");

    DCIteratorBinding dciter = hierBinding.getDCIteratorBinding ();

    NavigatableRowIterator nav = dciter.getNavigatableRowIterator ();

    NewRow row = nav.createRow ();

    newRow.setNewRowState (Row.STATUS_INITIALIZED);

    Line lastRow = nav.last ();

    int lastRowIndex = nav.getRangeIndexOf (lastRow);

    nav.insertRowAtRangeIndex (lastRowIndex + 1, newRow);

    dciter.setCurrentRowWithKey (newRow.getKey () .toStringFormat (true));

    Returns a null value.

    }

    For the case where you must add a line in different places of the table, see the link below:

    http://adfsonal.blogspot.in/2013/02/create-row-at-end-of-ADF-table.html

  • How to share several files at the same time?

    iI am trying to share a number of edited files and sending one at a time takes too much time. How to share several files at the same time?

    Yes, you can select and send/share several files at once.

    Start https://cloud.acrobat.com/send. Click Select files to send and then follow the instructions in file selection. If you want to add more files, simply click on add files:

    You can include up to 50 files by "transaction".

  • How to add more line by line?

    Hi all

    Please let me know how to add addition line by line as the title:

    DEPTNO num1, num2, num3 total num
    1100 20 30
    1200 20 10
    1300 40
    1400 30


    your suggestion would be greatly appreciated.

    Something like that?

     SELECT deptno,num1,num2,num3, num1+num2+num3 "Tot"
     FROM ....
    
  • How to add a line break in shortDesc?

    How to add a line break in shortDesc?

    Hey Danny,

    I think you can't... but I did two work around to achieve this goal:

    1. in IE7 (not Mozilla Firefox) If you type a space between the words will be automatically pass the new line like:


    shortDesc = "firstWord... spaces... Second word"/ >

    2. you can use popup like a ToolTip like:








    Sameh Nassar

Maybe you are looking for

  • App Tabs disappear whenever I close firefox

    I just created the application tabs using Firefox 4 RC, but when I closed Firefox App tabs I had put in place there where he went.

  • Where can I sell my Macbook Pro?

    Hi, I'm looking for a place to sell a Macbook Pro. I just upgraded to a new retina display that I bought second hand. I don't really want to deal with Ebay or Craigslist. I found a few alternatives including Gazelle, sell YourMac and TechGator.com an

  • Using Windows backup or Restore Wizard

    If I backed up the selected files (Documents and settings, programs and Windows operating system) on a secondary hard drive, why records are not visible on the disc, on which they have been saved? I see icons on the correct backup drive backup, but t

  • CDRW/DVD GCC4244

    My cd/dvd stop playback of the disc and my computer shows that it is installed but I get a code 19 and I don't know what to do so he could start reading my disks again.  Help, please...

  • surcurity essentials does not start, and the windows firewall does not illuminate

    Hello I have a problem, he seems to have had a virus on my pc. Essentials of security does not illuminate and the windows firewall will not also turn on, I tried to use the tool to "fix" windows and it doesn't solve the problem. the original virus se