Friday, March 26, 2010

Newbie is in need of help!

Hi, I'm really really a newbie to this Livecycle. I'm trying to create a form for the company I work for and need to create a button that will add an additional page for the user that is an exact duplicate of a page in the form. I'm really not familiar with scripting. Is there anyone there that can help me and is really patient? I'm sorry I am really bad at this stuff right now

Newbie is in need of help!

Hi,

Stick with it!!

Here is an example. There are a few important things you need to set up to get this to work:

  1. firstly adding pages is a dynamic feature, so you will need to save your form as an ''Adobe Dynamic XML Form''.
  2. next, there are two types of subform: ''Positioned'' and ''Flowed''. You will want a positioned subform for the page objects and then this is wrapped in a flowed subform, so that when you add a page it will flow onto the next page

Have a look at the example and in particular the Object tabs for the repeatingSubform and page1 (Subform and Pagination).

Hope that helps,

Niall

Newbie is in need of help!

Ok, so I saved as a dynamic XML....then I was looking at your example and that is EXACTLY what I want to do!!! It's WONDERFUL! Then I went to my window to the left listed as the ''heirarchy'' and clicked on my 3rd page (which is where I want to make this add page option available) and then changed the subform to ''positioned'' and made all the other options the exact same as yours and then wrapped it into a flowed subform. And what I think I am messing up is the button. I made it a click event, changed it to javascript language.

This is what my button says before I add anything:

form1.#subform[2].repeatingSubform.Button1::click - (JavaScript, client)

I don't know what to enter in after to make it work. I looked at your example and I am thinking maybe I messed up something in how I label my pages in the heirarchy? I attached my form for you to tell me what on earth I am doing wrong!

Am I so far doing this right? Thank you thank you thank you for all your help so far....I'm just a lowly building inspector....all I know is construction!!! I don't know what possessed me to take on something like this! I am really really really new at this, thank you for being so patient!

I've also included my form...the 3rd page is the one I need to duplicate. Please tell me where I am going wrong because I know it will be in a multitude of places!

Many thanks!

Hi,

Here is an amended version. It is nearly there, just a couple of things to bear in mind:

  • you should name objects as you go, particularaly if you are going to be referencing them in scripts. In particular pages and subforms. You will see I have given the pages a name and that the script in the click event of the button is much more straightforward;
  • The flowed subform is on the outside; the positioned (repeating subform) is inside that flowed subform;
  • You need to tell LC to repeat the positioned (repeating subform) in the Object / Binding tab.

LC is a very good tool for creating forms and checklists for construction works. Hang in there.

Hope that helps,

N

Civil Engineer

I GOT IT!!!!!!!

Thank you thank you thank you!!!!!!

Works PERFECTLY!!!!!!!!

No comments:

Post a Comment