Remove a line of table with a button in Livecycle Designer SS3

I have a table in Livecycle which includes 16 static lines. Several lines can be added or removed dynamically at the end of the table.

I want the user to be able to remove one of the static lines if they want to however I can't get the script to work.

I have a button at the end of the line with the script:

driverTable._Row2.removeInstance (true);

I tried various forms of this script such as do not use the abbreviation for 'instanceManager', leaving 'real' outside, etc. Where it says 'Row2' I would like to use this script for the following lines, Row3, etc. Row4.

I tried with the initial counter value of 1 and tried to zero. The table is in a fluid subform.

Can anyone help?

Hello

A line cannot be set to 0 cases, if you want to remove a line, you need to hide by using its property of presence...

But if you use 1 table for 16 different ranks, why don't you set the table with dynamic lines and have an initial 16 meter, then you can delete the lines you want with the removeInstance method

Tags: Adobe LiveCycle

Similar Questions

  • Deleting lines in a table with a button

    Good day all.

    I seemed to have encounter a problem with trying to add a delete button in a table that deletes a row. Let me expain.

    The form contains 1 table that has 7 elements composed of fields of text and drop downs. This table is in its own subform.

    There is a button to add lines that the user needs. The code I use to add lines: psl_list_subform.instanceManager.addInstance (1);

    I was asked to add a delete for a user button can delete rows. I added this at the end of the table. SO whenever a row is repeated, there's a button Delete. The code I am "trying" to use is;

    Table4.Row1.instanceManager.removeInstance (this.parent.index);

    When I click on the button Delete, nothing happens. I grew up the JavaScript debugger, there is no errors.

    Any ideas what I missed.

    Thank you all

    Chomp

    Hello

    my understanding of your form, you can add new instances of the "psl_list_subform" subform that contains a single table row.

    The hierarchy that resemble 'psl_list_subform. Table4.Row1.removeButton ".

    To remove an instance of the subform, a button in the row of the table, the script needs to refer to the 3rd parent of the button Delete.

    this.parent.parent.parent.instanceManager.removeInstance(this.parent.parent.parent.index);
    

    Explanation: this = Radiobutton2, 1 parent = Row1, 2nd parent = table 4, 3rd mother = psl_list_subform

  • I have a table with a button to add a line. Works fine except when the page is full, will not exercise in another page. Just gives me a blank page.

    See the image below. The figure is the view with the button. Figure 2, this is what happens when the expense to the other page, but failed to add more rows. In fact, it goes backward.

    FIGURE 1

    Capture01.PNG

    FIGURE 2

    Capture02.PNG

    Make sure to the table, you check the box "Allow the page break in content" under object-> Table

    ~ AEK

  • Remove identical lines of table

    Hello
    I use the apex of oracle 10g 3.2
    I have a table like this t_results

    RESULT_ID SERVICE_REGISTRATION_ID PARAMETER_ID RESULT
    20160 61947 484 0.9
    20161 61947 485 not measured
    20149 61947 484 0.9
    20151 61947 485 not measured
    20133 61948 475 0.1
    20155 61948 475 0.1
    20156 61948 475 0.1

    I want to remove identical lines like line 1 and line 3 are identical, too, tier 2 and tier 4.
    So I want to remove a line which is identical, i.e. Remove line 1 or line 3.
    There may be more then 2 identical rows.
    First pass is the primary key.

    I want to write one on load pl/sql block.

    How to do this?

    Thank you
    DELETE FROM table_t
      WHERE ROWID IN(
           SELECT ROWID
             FROM (SELECT ROWID,
                          ROW_NUMBER() OVER(
                             PARTITION BY result_id, service_registration_id, parameter_id, RESULT
                             ORDER BY ROWID) AS r
                     FROM table_t)
            WHERE r > 1);
    

    HTH, Urs

  • As a table with search button

    Hi all

    I have a table with the columns form: en Id Type_email
    E-mail type can have some values.
    I also made a page, named «Type-email search» element
    This article is a list of selection with certain values that can have the Type_email column.
    When I select one of the values, only the rows with this value should be included in the tabular presentation.
    Is someone can you please tell me how I can do?

    Thank you much in advance.

    Set up your report by adding this in your WHERE clause.

    SELECT ...
      FROM ...
     WHERE TYPE_EMAIL = :PX_TYPE_EMAIL
        AND ...
    

    As long as the value of return in your list of values is the datatype of the column in the report, you will have a match.

    Now, if you want to get a bit more fancy, you can also make your limited report If the limit value is set and if not, it will include all. The NVL command converts to:

    SELECT ...
      FROM ...
     WHERE TYPE_EMAIL = NVL(:PX_TYPE_EMAIL,TYPE_EMAIL)
        AND ...
    

    In this example, if your selection value returns null, you will get all values in your database, but if user selects something in the drop-down menu, you will see those. These types of selection lists are very practical for users.

  • Removal of MSQL 2 tables with a single button

    As I was able to add data from two tables mysql with a single button, I guess I should be able to delete the two entries in a similar way, but I can't seem to get there. The code is written in large part by DW and I have only the level minimum idea of the meaning of the php, so please be patient in no explanation as to where I'm wrong!
    At the present time, to the chk_sixmonth of the table entry is removed, but at table cel_contents incorrect records are deleted.
    The corresponding code is, I think;
    If ((isset($_POST['ck_pk'])) & & ($_POST ['ck_pk']! = "") & & (isset($_POST['gone']))) {}
    $deleteSQL = sprintf ("DELETE FROM chk_sixmonth WHERE ck_pk is %s",
    GetSQLValueString ($_POST ['ck_pk'], "int"));

    @mysql_select_db ($database_tormented3, $tormented3);
    $Result1 = mysql_query ($deleteSQL, $tormented3) or die (mysql_error ());

    $deleteGoTo = "chk_insert.php";
    If (isset {}
    $deleteGoTo. = (strpos ($deleteGoTo, '?'))? « & » : « ? » ;
    $deleteGoTo. = $_SERVER ['QUERY_STRING'];
    }
    header (sprintf ("location: %s", $deleteGoTo));
    }

    If ((isset($_POST['cel_pk'])) & & ($_POST ['cel_pk']! = "") & & (isset($_POST['gone']))) {}
    $deleteSQL = sprintf ("DELETE FROM cel_contents WHERE cel_pk is %s",
    GetSQLValueString ($_POST ['cel_pk'], "int"));

    @mysql_select_db ($database_tormented3, $tormented3);
    $Result1 = mysql_query ($deleteSQL, $tormented3) or die (mysql_error ());

    $deleteGoTo = "chk_insert.php";
    If (isset {}
    $deleteGoTo. = (strpos ($deleteGoTo, '?'))? « & » : « ? » ;
    $deleteGoTo. = $_SERVER ['QUERY_STRING'];
    }
    header (sprintf ("location: %s", $deleteGoTo));
    }

    $colname_rstSix = "1";
    If (isset($_GET['scrap'])) {}
    $colname_rstSix = (get_magic_quotes_gpc())? $_GET ["scrap"]: addslashes($_GET['scrap']);
    }
    @mysql_select_db ($database_tormented3, $tormented3);
    $query_rstSix = sprintf ("SELECT * FROM chk_sixmonth WHERE ck_pk = %s", $colname_rstSix);
    $rstSix = mysql_query ($query_rstSix, $tormented3) or die (mysql_error ());
    $row_rstSix = mysql_fetch_assoc ($rstSix);
    $totalRows_rstSix = mysql_num_rows ($rstSix);

    $colname_rstCont = "1";
    If (isset($_GET['scrap2'])) {}
    $colname_rstCont = (get_magic_quotes_gpc())? $_GET ['scrap2']: addslashes($_GET['scrap2']);
    }
    @mysql_select_db ($database_tormented3, $tormented3);
    $query_rstCont = sprintf ("SELECT * FROM cel_contents WHERE cel_pk = %s", $colname_rstCont);
    $rstCont = mysql_query ($query_rstCont, $tormented3) or die (mysql_error ());
    $row_rstCont = mysql_fetch_assoc ($rstCont);
    $totalRows_rstCont = mysql_num_rows ($rstCont);
    ? >
    <! DOCTYPE etc...

    < form action = "" method = "post" name = "scrap" id = "scrap" > "
    < input name = "gone" type = "checkbox" id = "gone" value = "gone" / >
    < input type = "submit" name = "Submit" value = "Remove" / >

    < input name = "ck_pk" type = "hidden" id = "ck_pk" value = "<?" PHP echo $row_rstSix ["ck_pk"];? ">" / >
    < input name = "cel_pk" type = "hidden" id = "cel_pk" value = "<?" PHP echo $row_rstCont ["cel_pk"];? ">" / >
    < / make >
    Thanks for any help

    Problem has now well sorted.

  • Add a line in a table with a button

    Good day to all;

    I think I have now lost...; >)

    Life cycle of Designer 8.05

    In any case, if the user of the form requires additional lines to enter the infoamtion, I want them to be able to add a line using a button. I tried to use the following

    "

    Table "N". Row2.instanceManager.addInstance (1); = "N" is the name of the table.

    I did it on a couple other forms but I must be missing something that I get the following error in Consol java

    "GeneralError: failed the operation."

    XFAObject.addInstance:1:XFA:form1 [0]: #subform [0]: #subform [1]: Button1 [0]: click

    The item [max] has violated its number of occurrences. »

    The form is registered as a form Arcobat 8 dynamic XML

    I have

    1 page is sent

    Subform is cast

    Someone would be kind enough to point me in the right direction.

    Thank you all

    Chomp

    Eventually, you forgot to put the line to be reapetable.

  • Simple table with radio buttons

    Hi guys,.

    I have here a simple table that contains a number of option buttons.

    Option buttons must be grouped by three, (you can select either 0, 1 or 2 in each column)

    I am having difficulties to consolidate the buttons as such.

    The form is attached.  Can someone help me?

    Thank you

    Hello

    You need three boxes into a single cell. Drag buttons 2 and 3 in the Group 1 exclusion of radio on the second column in the view hierarchy. To simulate a table, turn on the top and bottom of the cell lines and off up and down lines on three boxes. Get the boxes of the same size option (it helps to have snap to grid off the coast), same book and aligned. Remove the two bottom lines, and it should look like a table again.

    Good luck

    N.

    PS: If users are going to fill this in hand, you can follow the example of Jono and have radio buttons with a square and square hollow brand. The place is more intuiative on the page and even on the screen that the place stands out more against the choice of the user. I understand that the use of sunken places working against practices of the circles for the exclusion, but with your form groups, I suspect that clarity is important because the choice is perhaps "health"; "have you made a will? "beeeeeeeeep!" ;-)

  • Add dynamic lines to Table with the new access property

    Hi all

    I have a scenario where:

    1. I have a chart with lines including the readOnly property.

    2. I want to dynamically add a new row to the table, and this new line should be writable.

    3.I have added the following line in the click event of the button that adds a new line.

    form1.Table1.Row1.access="";
    

    But in the output line is added that is not writable.

    If we add

    form1.Table1.access = "";
    

    then new line is added, but it changes the access of all to the writing table.

    I want to change the access of the newly added line only and not the existing lines.

    How can do us?

    Thank you and best regards,

    Nikhil

    Hi Nikhil,

    Please refer script below, it would be useful to you...

    You must insert the script on the click event of the button below...

    Form1. Page1.Table1.Row3.instanceManager.addInstance (true);

    var countVal = (form1. Page1.Table1.Row3.instanceManager.Count - 1);

    xfa.resolveNode ("form1. Page1.Table1.Row3 ["+ countVal +"]. TextField1") .access ="open ";

    xfa.resolveNode ("form1. Page1.Table1.Row3 ["+ countVal +"]. TextField2") .access ="open ";

    xfa.resolveNode ("form1. Page1.Table1.Row3 ["+ countVal +"]. TextField3') .access = "open";

    This is what my table looks like.

    If it does not please let me know vl share the file.

    Thank you

    Vijay

  • Stored procedure to remove a number of tables with a common name attribute

    Hi all

    This is my first post so I hope I posted level with enough information. This is my first stored procedure (SP) and Oracle 10.

    I'm trying to write a script to remove 11 paintings and some lines of another 3 tables, which are named with a number I want to enter at the time of the creation of MS below is the script that I wrote and edited. My original was lost by crashing the servers!

    When I run the script, it gives me the following output:

    "WARNING: execution completed with warning.
    procedure ScenarioDelete update"

    MS has not deleted one of these tables and I don't know if it's because my script is poor or because of something else. Any help is greatly appreciated!

    -table remove SP
    --
    -Race start ScenarioDelete ('x'); with the idscenario x

    create or replace procedure ScenarioDelete (ScenarioNo IN varchar2);
    countstable: = "C_". ScenarioNo;
    CHANGETABLE: = "CG_" | ScenarioNo;
    countsinfotable: = 'CI_ ' | ScenarioNo;
    DataTable1: = "D_0_" | ScenarioNo;
    datatable2: = "D_1_" | ScenarioNo;
    datatable3: = 'D_2_ ' | ScenarioNo;
    hietable1: = 'HI_0_ ' | ScenarioNo;
    hietable2: = 'HI_1_ ' | ScenarioNo;
    hietable3: = 'HI_2_ ' | ScenarioNo;
    hielinktable1: = 'HL_1_ ' | ScenarioNo;
    hielinktable2: = 'HL_2_ ' | ScenarioNo;

    AS

    run immediately 'drop table ' | countstable;
    run immediately 'drop table ' | CHANGETABLE;
    run immediately 'drop table ' | countsinfotable;
    run immediately 'drop table ' | DataTable1;
    run immediately 'drop table ' | datatable2;
    run immediately 'drop table ' | datatable3;
    run immediately 'drop table ' | hietable1;
    run immediately 'drop table ' | hietable2;
    run immediately 'drop table ' | hietable3;
    run immediately 'drop table ' | hielinktable1;
    run immediately 'drop table ' | hielinktable2;

    immediately execute "delete from USERACESS where IDSCENARIO = ' |" ScenarioNo;
    run immediately "remove scenario where IDSCENARIO = ' |" ScenarioNo;
    immediately execute "delete from SCENARIOINFO where IDSCENARIO = ' |" ScenarioNo;

    -or-

    run immediately "delete from USERACESS where IDSCENARIO =" | " ScenarioNo | ''';
    run immediately "remove scenario where IDSCENARIO =" | " ScenarioNo | ''';
    run immediately "delete from SCENARIOINFO where IDSCENARIO =" | " ScenarioNo | ''';

    END;

    Hello

    Welcome to the RTO

    If you allow me, I would like to make a suggestion to simplify your code

    Create OR Replace Procedure ScenarioDelete(ScenarioNo IN Varchar2)
    As
       Type t_DropTable Is Table Of Varchar2(30);
       v_DropTable t_DropTable := t_DropTable( 'C_', 'CG_', 'CI_', 'D_0_', 'D_1_', 'D_2_', 'HI_0_', 'HI_1_', 'HI_2_', 'HL_1_', 'HL_2_' );
    
       Type t_DeleteTable Is Table Of Varchar2(30);
       v_DeleteTable t_DeleteTable := t_DeleteTable( 'USERACESS', 'SCENARIO', 'SCENARIOINFO' );
    Begin
       -- Drop tables
       For i IN v_DropTable.First .. v_DropTable.Last Loop
          Execute Immediate 'DROP TABLE ' || v_DropTable(i) || ScenarioNo;
       End Loop;
    
       -- Delete tables
       For i IN v_DeleteTable.First .. v_DeleteTable.Last Loop
          Execute Immediate 'DELETE FROM ' || v_DeleteTable(i) || ' WHERE SCENARIOID = ' || ScenarioNo;
       End Loop;
    End;
    

    Kind regards

    Christian Balz

  • Operation on line on table with a For loop

    Hello

    I work with a wide range of dimensions column one. I'm doing the following

    for i = 1:size (A) / 2

    B (i, :) = A (1 + (i-1) * 2:i * 2))

    So, for example if

    A =.

    0

    1

    2
    3
    4
    5
    6
    7

    then

    B =

    0 1

    2 3
    4 5
    6 7

    My approach was to use a subset of the table inside the loop for to select several items, but I don't know how to transpose the selected items in a new line to create the table (B) is there a simpler approach?

    Thank you

    Mike

    try experimenting with the table to reshape feeding your table entry and re-sizing for a 2d aray of output. It is much faster to use a loop For, because the data is never moved and LV just changes the dimensions of the matrix and updates the stride.

    Ben

  • To remove the line on click of a button

    Hi friends,

    I use JDeveloper 11.1.1.5.0.

    I have a table full of 10 lines. I have a delete button. Click on the button I want to delete the selected line.

    The method works well, but compared to the level of the page it will not be deleted immediately.

    If I refresh the page, then it shows that the line is deleted.

    Please help me.

    Thank you

    $@M$

    Add the following two lines in your code before the return of rt;

    this.getEmployeeDetailsVO1().clearCache() ;
    this.getEmployeeDetailsVO1().executeQuery() ;
    

    as for your code below

    ExternalContext ectx =
    FacesContext.getCurrentInstance().getExternalContext();
    HttpServletResponse response = (HttpServletResponse)ectx.getResponse();
    HttpSession SessionId = (HttpSession)ectx.getSession(true);
    String Id = (String)SessionId.getAttribute("Id");
    

    You can simply use

    String Id = (String)ADFContext.getCurrent().getSessionScope().get("Id");
    

    And the value in use of session

    ADFContext.getCurrent().getSessionScope().put("Id","YOUR_VALUE");
    

    Let me know if it works for you :)

  • Adding a table with a button, how to specify the location?

    I have a form of have been a table is duplicated by using a button and the instance script Add.  Is there one had to specify which direction or location of the table is added.  I guess that by default it is created as the original table.  I would like that it is created to the right of the original table.  This option can be changed or scripted somehow?  Thank you

    Hello

    If you repeat the whole table, it is within a subform flowed. The default value is cast from top to bottom. If you change this Western style, objects will be flowing from left to right.

    However, it is because there is the space to the right of the form to receive the new instance.

    Here are some examples:

    https://Acrobat.com/#d=aFfqJJrwjDbVOuT96bD8Ug

    https://Acrobat.com/#d=4QBgZy0pBIV9IoMlKP0lRg

    Good luck

    Niall

  • Remove the current instance of a line in a table with formcalc using removeinstance

    I'm new on this and to find most of my answers with the help of Adobe or some other resources I have but this one left me speechless.  I have a table and a button to add lines.  After the lines are added and filled I need users to be able to delete some of them.  I have a delete button added to the last column of the table and the button strives to remove an instance of the table, the problem is that the instance that is being removed is evil, is always the first step on the line that the button is in.  If anyone can help, here's what I have:

    Table1._Row1.removeInstance (1)

    I know that 1 is not fair, but what I do to delete the current line that the button is.

    Thank you!

    Hello

    The setting for the done removeInstance() refers to the index of the repeat line you want to delete. This is a base zero index.

    If you replace the 1 in media with:

    This.parent.index

    It shoul work.

    See an example here: http://assure.ly/gk8Q7a

    Niall

  • How to remove newly added line in table advanced

    Hello

    It comes to 12.1.3.

    I have a case of use with advanced table and the "Add Row" button.

    The user can add two lines (empty), field 2 (both part of PK, the two LOVs), then start filling, then realizes he added too many, because the TooManyObjectsException exception is thrown. What would be the 'Nice' way of having the last added row deleted, or some newly added lines to delete if a few lines have been added (before actually trying to commit). I mean how must reference any row that has been added and should be removed - this line do always not PK (PK because not even adjustable due to violation of PK if this makes sense). Is there a fun/easier way to do it? Would be great if someone could share a line or two...

    Thank you

    Anatoliy

    PS

    I have a delete button in a footer with action to fire the event as 'remove' in LICS, I like below, and copy the following code deletes the LAST record in the advanced table, not the one where the cursor is?

    If ("delete".equals (pageContext.getParameter (EVENT_PARAM)))
    {
    String rowRef = pageContext.getParameter (OAWebBeanConstants.EVENT_SOURCE_ROW_REFERENCE);
    Line OARow = (OARow) am.findRowByRef (rowRef);
    Row.Remove ();
    }

    Asmirnov-Oracle wrote:

    Hello

    Yes, I actually try this approach too.

    Have what approach you tried? 1 or 2?

    If you try to follow the second approach, you can try this?

    OAViewObject srcAppvo = (OAViewObject)findViewObject("SrcAppVO1");
    if (srcAppvo != null) {
        RowSetIterator srcAppRowItr =
            srcAppvo.createRowSetIterator("srcAppRowItr");
    
        try {
            Row srcAppRow;
            srcAppRowItr.setRangeStart(0);
            srcAppRowItr.setRangeSize(srcAppvo.getFetchedRowCount());
            int recCnt = srcAppvo.getFetchedRowCount();
            while (srcAppRowItr.hasNext()) {
                srcAppRow =
                        srcAppRowItr.next();
                if (srcAppRow != null) {
                    if (srcAppRow.getAttribute("SelectFlag") != null &&
                        srcAppRow.getAttribute("SelectFlag").toString().equals("Y")) {
                        srcAppRow.remove();
                    }
                }
            }
        } finally {
            srcAppRowItr.closeRowSetIterator();
        }
    }
    

Maybe you are looking for