Highlighted

Livecycle - Printing Text field

Avatar

Guest

06-08-2008

I am new to using livecycle. I have created a form with a multiline text fields. I noticed when the text field is filled in with information and it exceeds the what you can "see" on the screen a scroll bar turns on so you can view the entire inputted text.



My problem is with printing. When the PDF file is filled in and the above situation occurs, it will only print what can be viewed in the text box on the screen. All the other data that you would have to scroll down to see in the electronic file is not printed. Any help is appreciated. Thank you.

Replies

Highlighted

pguerett

06-08-2008

There are a number of ways to handle this and it ranges from the simple to the complicated.



1. You can limit the amount of input that goes into the field to the visible area. This way no scroll bars will appear and there will be no area off screen. To do this put focus on the field in question and in the Object/Field palette click on the "Limit Length to Visible Area" checkbox.



2. You can have it so that when a user fills the box the text will shrink to fit the visible area. Put Focus on your field object. Do not limit the length to visible area. In the font palette (if it is not visible hit shift - F4). Make sure that you are only editing the value property. Set the font to 0.



3. Redo the form so that the field will automatically grow when the field is overflowed. The scroll bars will appear when you are typing in th efield put when you leave the field it will grow to accomodate the text. There is an example of doing this in the Purchase Order sample that ships with the product. You will have to redesign your form to build it as a dynamic form. Follow this example if you want this solution. Look in the designer install directory/EN/Samples/Forms/Purchase Order/Dynamic Interactive/Forms



Once you open the form have a look at the Comments field. This is one of those fields. Note only do this technique if you know what you are doing!
Highlighted

Avatar

Guest

01-10-2008

I have Designer 7.0 and there is no "Limit length to visible area" checkbox in the object/field palette. There is only "Limit length" and "max char."



Please advise because I would love to limit the length to the visible area without resizing the text option.



Thank you...
Highlighted

Ryan_Lunka

01-10-2008

Without the "limit length to visible area" option, you can't REALLY do it. My suggestion would be to fill the field in with WWWWWW... until it is full, but not overflowing, count how many chars there are, and set that as your max. I'm pretty sure W is the widest character in most fonts, so if you max it out at how many Ws will fit, it should never really get any bigger.



That's kind of a workaround though. The problem there is if you type anything less than all Ws it will restrict the user before it reaches the edge of the text field.



You could also play with the "Auto-fit" option beneath the Height in the Layout tab. You may be able to make it expand itself downward to fit more text.
Highlighted

pguerett

01-10-2008

I do not know about the upgrade but in that version you can use an Acroform command to accomplsh the same thing.



To get access to the doc object in Acroform you can use event.doc. The property you want is doNotScroll. So you can code something like this:



var myDoc = event.target;

myDoc.getField("form1[0].Page1[0].Sunform1[0].Field1[0]").doNotScroll = true;



Where the field name in bewteen the quotes is the name as AcroForm woudl see it. This will not allow scroll bars and will limit the user to entering text in the viewable area only.



Another solution is to shrink the text in the visible are so that it all fits. You can do this by making the field multi-ine and having a font size for the Value of the field set to 0. When the field is full the fontsize will reduce so that all text will appear in the visible area. Note that if the user is verbose that you coudl reduce the size of the characters to an unreadable size.
Highlighted

Avatar

Guest

01-10-2008

Thank you for this info. I have not used Acroform before. Is this a separate program? Where do I get access to it in LiveCYcle Designer 7.0?
Highlighted

pguerett

02-10-2008

AcroForm is the base technology that PDF uses to make form objects. It has been in Acrobat for some time (version 4 I think). Designer uses a different technology that is XML based called XML Forms Architecture (XFA). That is what you are creating in Designer. When you create a PDF out of an XFA form you are infact turning it into AcroForm technology so Acrobat can display it. The idea was that anythingyou could do with AcroForm woudl be exposed to XFA so that you as a Designer would not have to know or care about which side was being used. Clearly a few things were missed and added over time. There is an Acrobat Javascript reference where this info comes from but I would recommend that you stay in the XFA world and only venture there when absolutely required.
Highlighted

Avatar

Guest

02-10-2008

Thank you for that explanation. The one thing I don't understand yet is where to enter the code:



var myDoc = event.target;

myDoc.getField("form1[0].Page1[0].Sunform1[0].Field1[0]").doNotScroll = true;



Please give me the steps of where to put it.



Thanks again for all your help.