Question about Looping through tables in Adobe Form

Hello,
We have an adobe form which is to be filled offline. It consists of a table. Table can have repeating rows and user can add\remove rows as they wish.  The cardinality of the context node where we need to bind this table data is set to 1…n
We want to know the process to get all the values in the table back into our context node once the form is uploaded. I assume we need to loop through the table, and add elements to the context node.  Can someone please let us know if we’re on the right track, and provide some sample code if possible?
<b>We can’t figure out a way to loop through a table inside an Adobe form.</b>
We are using Web Dynpro Java with Adobe Livecycle Designer 7.1
Your help is much appreciated.
Thanks,
Rob.

Try using...
for (z = 0; z < 16; z++) {
     this["cb"+z].setStyle("styleName", "cssCBstyle");
That is the way to target them.  I haven't dealt with setting styles, so I can't answer for that aspect working or not.

Similar Messages

  • Looping through table in ADOBE TABLE...HOW?

    Hi,
    I'm having a problem with writing scripts on looping through a dynamic table in adobe and disabling certain cell in the table.
    can some one write me the script to help me out...please.... here is my email add. [email protected]
    Regards,
    Vinod

    Hi Denise
    You can use tableView for this which is available in htmlb.
    There is a attribute in tableView called visibleRowCount.
    The integer value that u give for this attribute , only that number of rows will be visible on your BSP page.
    This is the sample code :
          <htmlb:tableView id              = "tb1"
                           headerText      = "Communication"
                           headerVisible   = "true"
                           design          = "alternating"
                           visibleRowCount = "4"
                           fillUpEmptyRows = "true"
                           table           = "<%= itab %>" >
                    <htmlb:tableViewColumn
                     columnName     = "CURRENT_STATE"
                     title          = "CURRENT STATE"
                     edit           = "TRUE" />
    .                     </htmlb:tableView>
    Here tableview id  and table is mandotory field.
    Give as many tableViewColumn as u have column in your internal table ( Here CURRENT_STATE is the name of the Column that I have in my internal table).
    Here visibleRowCount is 5, so only 5 rows will be visible at a time .For other entries u have to click on
    my click handler which is like a footer in a tableView, and next 5 entries will become visible and like that.
    Before implementing this, fill your internal table
    in OnCreate in Flow logic ( in do_init in case of MVC).

  • Merging of cells of a dynamic table in adobe form

    Hi,
    I am trying to Merge 2 columns in a dynamic table in adobe form.The requirement is to merge column 3 and column 4 if column 4 is empty. I used the below javascript code in both "Form ready " and Initialize event of the row.
    if (this.Cell4.rawValue == " ")
    this.Cell3.colSpan = "2";
    this.Cell4.presence = "hidden";
    Note : Since above code was not working , i used the below code in my subform also but it did not returned desired output.
    if(Table22.Row1.Cell1.rawValue == " ")
    Table22.Row1.Cell3.colSpan = "2";
    Table22.Row1.Cell4.presence = "hidden";
    The problem is that in my dynamic table , its the second row where the requirement is fulfilled ie in the 2nd entry of my table the column4 is blank (the exact row number might change depending on input data).
    is there a way to loop in the dynamic table and check if column 4 is empty for a particular row.
    the above code does not help to fulfill my requirements. kindly help.
    Thanks
    Aditi

    Hello Aditi priya,
    Hope you are doing good..
    Please go through my recent blog..
    http://scn.sap.com/community/interactive-forms-by-adobe/blog/2015/01/02/merging-internal-table-cells-dynamically-in-sap-adobe-forms-using-java-script-code
    I hope you will find all answers from this blog..Reward if helpful...
    Thanks & Regards,
    B Raghu Prasad

  • How to use nested tables in adobe form

    Hi All,
    I have to use nested tables in adobe form for table display. I have used Subforms for displaying table data. I have changed accessibility of the subforms. Currently i am able to print print the table correctly if there is single material record in table 1 and single corresponding record in table 2. But the requirement is that i will have multiple lines in table 1 for single material and only one record in table 2.
    EX: form is for Sales order. in line items if the order is for 100 units then we if we have delivered material as 80, 10, 10, then table 1 will have 3 lines for this. Table 2 will always have only 1 corresponding record.
    item--materialdescription-ordered qty--delivered qty--delivery date-price  
    xxx--xxxxxxx-xxxxxxxxx-10080xxxxxxxxxx-xxxx
    10----
    xxxxxxxxxx
    10----
    xxxxxxxxxx
    yyyyyyyyyyyyyyyyyyy------yyyyyyyyyyyyyyyyyyyyy 
    xxxxxx is table 1 and will have multiple lines
    yyyyyy is table 2 and will have only 1 entry for item xxx
    and this group will be repeate as per no of items. table 1 can have any no of lines per item.
    I am currently able to display 1 line for table 1 and 1 line for table 2.
    But how to show multiple lines for table 1 and 1 line for table 2.

    HI,
          Set the body page as flowed and set the tables also flowed.
    go to bodypage>object->subform-->select flowed option.
    I thihnk this will work..if u are getting all the records properly into the tables 1 and 2.
    Thanks,
    Mahdukar

  • How do I loop through tables, not columns in a table?

    Sorry if this is a long one. My problem is actually quite simple. I am trying to write either an ad hoc PL/SQL block or a stored procedure to loop 18 times (thru 18 tables) and perform a SQL query on those tables, returning 18 resultsets. I would like the results to show up on the screen (or in a spool file, whatever).
    So far I have tried 3 different approaches, none of which have worked.
    1. I tried to assign the select query to a variable (qry) and use EXECUTE IMMEDIATE qry. This forced me thru a variety of errors to declare variables and assign the result to them--EXECUTE IMMEDIATE qry into nm0, nm1, nm2...
    The problem with that was the resultset returned more than the variable was built for as there might be no rows returned, or it might be a thousand rows of data. So I tried changing the variables to VARRAYS, but it gave me a type mismatch as the underlying columns were NUMBER and VARCHAR2.
    DECLARE
         ctr number;
         TYPE NUMLIST IS VARRAY (1000) OF NUMBER;
         TYPE VARLIST IS VARRAY (1000) OF VARCHAR2(15);
         nm0 NUMLIST NOT NULL DEFAULT 1;
         nm1 VARLIST;
         nm2 NUMLIST NOT NULL DEFAULT 1;
         nm3 VARLIST;
         nm17 NUMLIST NOT NULL DEFAULT 1;
         qry VARCHAR2(2000) := 'klx_uln_p000_cells';
    BEGIN
    FOR ctr IN 1..17 LOOP
         IF ctr &lt; 10 THEN
              qry := 'SELECT
              A.DIM_0_INDEX,
              S0.SYM_NAME,
              A.DIM_1_INDEX,
              S1.SYM_NAME,
              A.DIM_2_INDEX,
              S2.SYM_NAME,
              A.DIM_3_INDEX,
              S3.SYM_NAME,
              A.NUMERIC_VALUE,
              B.NUMERIC_VALUE
              FROM
              KHALIX.klx_uln_p00'||ctr||'_cells A,
              KHALIX.klx_ucn_p00'||ctr||'_cells B,
              KHALIX.KLX_MASTER_SYMBOL S0,
              KHALIX.KLX_MASTER_SYMBOL S1,
              KHALIX.KLX_MASTER_SYMBOL S7
              WHERE
              A.DIM_0_INDEX=B.DIM_0_INDEX AND
              A.DIM_1_INDEX=B.DIM_1_INDEX AND...
              A.DIM_7_INDEX=S7.SYM_INDEX';
         ELSE
              qry := 'SELECT
              A.DIM_0_INDEX...
              A.DIM_7_INDEX=S7.SYM_INDEX';
         END IF;
         BEGIN
         dbms_output.put_line('SELECT FOR KLX_ULN_P00'||ctr||'_CELLS');
         dbms_output.put_line(nm16);
         dbms_output.put_line(nm17);
         EXECUTE IMMEDIATE qry into nm0,nm1,nm2,nm3,nm4,nm5,nm6,nm7,nm8,nm9,nm10,nm11,nm12,nm13,nm14,nm15,nm16,nm17;
    --     dbms_output.put_line(qry);
         dbms_output.put_line(nm16);
         dbms_output.put_line(nm17);
         EXCEPTION
              WHEN NO_DATA_FOUND THEN
                   dbms_output.put_line('No data found for Query '||ctr);
         END;
    END LOOP;
    EXCEPTION
         WHEN NO_DATA_FOUND THEN
              dbms_output.put_line('No data found for Query '||ctr);
    END;
    2. So then I used REF CURSOR to create a stored procedure and return the values. That allowed me to run my query AND tokenize the tablenames with a counter so that it would loop through the different tables! However, I still could not get it to display the results without going to SQL Plus and typing 'print c;'.
    3. So, finally I tried to create a looping wrapper around the ref cursor to have some variable (ctr) increment so my query would get performed on table0_cells through table17_cells. This, too, did not work.
    If I manually go to SQL Plus and type:
    variable ctr number
    begin
    :ctr := 1;
    end;
    exec dupe_find(1,:c);
    it will execute for the first table (klx_uln_p001_cells) and I can then type 'print c' to see what was returned. But when I try putting this within a wrapper PL/SQL block with a Loop to make ctr go from 0 - 17 (to loop through table_names klx_uln_p000_cells to klx_uln_p017_cells), it does not work.
    Help! It should be very simple to loop through tables, shouldn't it? I just want a script that will loop through tables, perform a query on each table and display the results. For some reason, I can only find documentation examples on looping through columns that are all in the same table.
    Dave

    Here's a working example using your first strategy ...
    create table t1 (id number);
    create table t2 (id number);
    insert into t1 values (100);
    insert into t1 values (101);
    insert into t2 values (200);
    insert into t2 values (201);
    declare
    v_table_name user_tables.table_name%type;
    type ttab_id is table of t1.id%type index by binary_integer;
    tab_id ttab_id;
    begin
    for i in 1 .. 2 loop
    v_table_name := 't' || i;
    execute immediate 'select id from ' || v_table_name
    bulk collect into tab_id;
    dbms_output.put_line('query from ' || v_table_name);
    for j in 1 .. tab_id.count loop
    dbms_output.put_line(tab_id(j));
    end loop;
    end loop;
    end;
    There are many other ways to do this (especially if you need to do more than just print out the data).
    Richard

  • How do I get to have more than 20 columns in a table in adobe form?

    I see that there is limitaion to not have more than 20 columns in my table in adobe form, Is there any way I can have more than 20 columns in a table in adobe form in landscape mode.

    Hi,
    That only relates to the Table Wizard. Once the table is placed on the page, you can add columns manually, from the menu or right-clicking on a column.
    You can also use fields within a repeating subform (instead of the table object).
    Good luck,
    Niall

  • Problem with table in Adobe Form in Web Dynpro JAVA??

    Hello all,
    I have an issue with the table displaying all the node values in the Adove Form. Right now it displays only the first element of the Node even if there are multiple entries.
    Not sure what is going wrong here.
    How is the table created in a interactive form? Any help is appreciated.
    Thank you, John

    Siva,
    I referred to the website, but still having issues with generating tables in Adobe Form. I can get all the table rows in the adove form, but the pdf doee not add new pages to display all the table rows. It just createa one page with the table inside it, display few of the rows and truncates rest of the table data.
    Here is the heirarchy of the page with the properties set
    Master Pages ---
            ||--> Page 1
                     ||--> content area
                     ||--> subfrom (properties:: Content - Flowed / Flow direction - top to bottom...pagination tab is greayed out completly)
                                ||--> Table
                                          ||--> HeaderRows (Object: Row - Type: Header Row)
                                          ||--> Row1 (Object Tab/Binding: Repeat Row for each data item - checked)
    Can't make it wor, not sure what's wrong here
    I am using NDS 7.0 SP18 and Adobe LiveCycle 8.0. Does that could be a problem.
    Appreciate your help
    John

  • Restricting visibility of table in Adobe form in WdJava when node is empty.

    Dear Experts,
    We have a requirement for Formcalc or Javascript code for making the table on adobe form invisible when the node corresponding for the table in the form is empty.
    Please suggest ASAP. Thanks in advance.
    Regards,
    Mahesh.

    Hi
    In the table's layout ready event write the following.
    //formCalc
    if(data.Page.<table>.<Row1>.<field>.rawValue == null or data.Page.<table>.<Row1>.<field>.rawValue == "" ) then
    $.presence = "hidden"
    //this.presence = "hidden"
    endif
    Kind Regards
    Mukesh
    Edited by: Mukesh mani on Nov 23, 2009 1:26 PM

  • Printing data from table in Adobe Form.

    Hi all,
        How can i print all data from my internal table in adobe form.currently only last record from table is getting printed.i have put my table is in sub form and content i have made 'Flowed'. is there anything else i have to do to make all data from my internal table appear.
    Thanks & Regards,
    Anjana Rao

    HI Nimesh,
    This looks ok and works well, but the problem is its not printing the header data, all the headings its leaving that place as blank. Do you have any suggestion for this. This is the code is used.
    DATA: pgm LIKE sy-repid,
            tc  TYPE cxtab_control.
      pgm = sy-repid.
      tc  = tab.
    CALL FUNCTION 'FITRV_PRINT_TABLE_CONTROL_DATA'
        EXPORTING
          TABLE_CONTROL                        =  tc
          CALLBACK_PROGRAM                     =  pgm
         CALLBACK_TOP_OF_LIST                 =    'TABLE_TOP_OF_LIST'
        CALLBACK_TOP_OF_PAGE                 =
        CALLBACK_END_OF_PAGE                 =
        CALLBACK_END_OF_LIST                 =
         OPTIMIZE_COLUMN_WIDTH                = 'X'
         GET_CURR_QUAN_FIELDS_FROM_DDIC       = 'X'
        WINDOW_TITLE                         = 'PRINT TABLE'
          PRINT_IMMEDIATELY                    = 'X'
        TABLES
          PRINT_DATA                           =  ITAB
       EXCEPTIONS
         COLUMN_INFORMATION_MISSING           = 1
         PRINTING_NOT_POSSIBLE                = 2
         OTHERS                               = 3
      IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
             WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
    Thanks,
    Venkat

  • Create multiple tables in adobe form

    hi,
    Is there anyone can tell me how to create multiple tables in Adobe Form using SAP Netweaver Developer Studio. Are there any steps i can follow?

    Hi,
    Define  the tables in subforms and then wrap them into another subform and make it the subform as type flowed.
    Regards,
    Raju.

  • How to avoid overlapping of Table on another table in Adobe Form

    Hi Experts ,
                  Can anyone tell me how to do this scenario,When I am inserting 3 flowable tables in Adobe form ,issue is one form is overlapping over another, All the internal tables has 10 records minimum. Requirement is after one table is printed Next table should be start printing without overlapping on next further table... Please let me know How to avoid overlapping of table on another table.Advance thanks.
    Thanks & Regards
    Sandesh

    Hi Sandesh.
    Put your table in subform. (one for each)
    And than add one more subform and include all 3 table's subforms in single subforms.
    All subforms should be flowed.
    With Regards,
    JP

  • Overlapping two tables in adobe form

    Hi
    I have a requirement to print details based on different bill numbers in different pages. 
    I have two internal tables 
                    1. it_inrt  containing two fields 
                    2. it_prts containing four fields  .
    Tthese two tables are looping separately. during program execution it_inrt overlaps it_prts. my question is that how to prevent this overlapping i want to print it_prts only after printing all rows of it_inrt and the excess rows will continue in  the next page.
    Please help me to solve this problem.

    Hi,
    You have to 2 internal tables right,
    You have to print the data which is in First internal table and same for second internal table..
    Place thes to tables(one after another ) in Desgin page of - Adobe forms..
    Under page there is  Untitled content area and renamed as ( page area 1)
    In hierachy tab -  By default you will see the Untiled Subform page ( Here drag the First Internal table to here and change the   subflow as flowed ,pagiantaion as continued in untitled area). add another internal table to this form..
    create a new page with only Untitled content area and renamed as ( page area 2)
    Steps:
    Select Untitiled subform - under pagination - Place Select ( In content area of page area 1 )
                                              if dataset must be paginated -  overflow to ( Go to content area of Page area 2 )
                                            - under subform - make the content as flowed and check the allow page breaks within content.
    Regards,
    PraVeen
    Edited by: praveenreddys on Feb 21, 2012 3:53 PM

  • How to modify automatically the show length of table in adobe form

    hi,experts.
    i often need adobe form to output imformations in table forms..sometimes i don't know the length of each column previous. so i want to make that the adobe form can adjust the output length of table column automatically depending on the content..
      i am new about JavaScript of adobe forms.  hope someone can give me suggestions
    thanks in advance.

    Hi,
    You may select the particular column and then in the Layout Pallette, select the radio button for "Expand to Fit" which would be under Height. That way your cells would automatically adjust for size(Would grow in height). But the size wont grow in Width, that remains fixed as  you would have fixed during design time.
    Regards,
    Runal

  • Loop through table's rows

    Hi folks,
    I have a table with multiple rows which each one of them contains one dropdown list.
    In my code I want to loop through this table rows and check each dropdown list's selected-item.
    How can I do this in code(JavaScript).
    Thank you,
    Yair

    Check this thread,
    it has solutions for JavaScript ind FormCalc.
    http://forums.adobe.com/message/3345384#3345384

  • Multiple rows in a single table cell - Adobe forms

    Dear All
    I am developing an adobe form which conatins a table alongwith other screen/ form elements.
    This table is bound to a data node and contains only two columns. Number of rows will be determined at run time.
    Each cell of the table will contain three rows seperated by a space in between them. Please refer to the diagram below for more understanding.
    Yes
    ABC
    No
    PQR
    Not Known
    XYZ
    I have no idea how to achieve this.  Can anyone help?
    Regards
    Vineet Vikram

    Hi,
    Here are the steps how you can do it.
    1. Create a table.
    2. In the Library palette, click the Standard category and drag the Table object into a cell in the main table.
    Note: If you selected Donu2019t Show This Again in the Insert Table dialog box, when you select the Table object from the Library palette, LiveCycle Designer automatically inserts a table with the same number of columns and rows that you inserted the last time you used the Insert Table dialog box.
    3. In the Insert Table dialog box, enter the number of columns and rows. You can enter a maximum of 20 columns and 50 rows. You can add more columns and rows after the table is created by using the Insert commands on the Table menu.
    4. To add a header row, select Include Header Row In Table.
    5. To add a footer row, select the Include Footer Row In Table.
    6. Click OK.
    Regards
    Runal

Maybe you are looking for

  • Status: Pending on Texts Sent

    I have sent a text message and on the message report is says "Status: Pending"  Anyone know what this means?  Did my message go through?  The message was sent a few weeks ago and it still says the same thing.  Thoughts?  I do not want to send anymore

  • Is it possible to turn off CSS and design text with HTML only?

    I'm trying to design text with HTML only ie: Font, Color, Size. The only method I'm aware of is to highlight the text and then go to Insert> Html> Text Objects. That method is tedious and time consuming. I'm not looking for arguments or reasons as to

  • How can I sent a parameter into Having sentence.

    I want to create a VO by the below sentence. SELECT fte.employee_id, fte.salary, fte.position_code FROM fwk_tbx_employees fte GROUP BY fte.employee_id, fte.salary, fte.position_code HAVING COUNT(fte.salary) >= :1 But I have no idea to set the paramet

  • Map's opens then shuts off

    Yes i recently updated to 1.1.3 about a week ago. Maps worked fine, well i am in Atlanta and used my Map's quite a bit on the way here. Well all of a sudden I go to open it and it opens and acts like its going to load then just kinda goes black and g

  • Canon hv 20 compatability

    Does anyone know how to get FCE to recognize new Canon hv 20?