nextNode() or cloneNode() - InfoPath Dev
in

InfoPath Dev

nextNode() or cloneNode()

Last post 08-04-2010 03:21 PM by AzuDaioh. 0 replies.
Page 1 of 1 (1 items)
Sort Posts: Previous Next
  • 08-04-2010 03:21 PM

    nextNode() or cloneNode()

    Hi Everyone, I'm hoping someone could help me out. I'm a noob with codes.  I found these from various sources and I couldnt figure out why a function stopped working after I added a new similar function.  They could be conflicting but I dont know why. The code works before I started the other function. But when I try to complete another form, it gives me an error message regarding this line of code. Something to do with 'null is null or not an object'. This is the line that is being pointed out by the error message:

    var oNewRow2 = oSampleRow2.cloneNode(true);

    Basically, I have 3 repeating table in my form:
    #1 - Payment Records: this must maintain the original data so I clone this into another repeating table (#2)
    #2 - Overpayment Details: this repeating table contains data from #1 but with additional columns to calculate the overpayment. The reason for cloning table#1 is because sometimes we need to split 1 payment into multiple rows to display the detailed overpayment.  Since there would be a chance of adding new rows, I cannot use the same table as #1.
    # 3 - Print Preview version: this is basically a clone of #2, all the data are identical, but I need to be able to print the table headers when printing multiple pages.

    ------------

     Edited:

    I removed the functions because I solved this issue.  It was due to a control in the same section as repeating table#2 but not part of the repeating table.  After I moved the field to another group, the code worked again.  Sorry for bothering you guys.

     

     

     

Page 1 of 1 (1 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.