Expand my Community achievements bar.

Guidelines for the Responsible Use of Generative AI in the Experience Cloud Community.
SOLVED

Print just what is typed in the text field without printing the text fields

Avatar

Former Community Member

Hello,

I'm trying to print a form after I filled in the text fields, but would like it to print just what I typed in the field, not the text field and the color in the text field. I use CS3.

Any help would be appreciated!

1 Accepted Solution

Avatar

Correct answer by
Level 4

Hello Teddy and wellcome to the group!

If you want to change fonts or other things then you might need to use the PrePrint method. What I normally do is select PrePrint from the "Show" section in the Script Editor (If you do not have it go to the toolbar at the top, Windows, and select Script Editor). After you select PrePrint you can now either type the name of the subform and field you want to change (or you can put your cursor in the Scripting Dialog box, hold CTRL and then select the field with your mouse) and then type in the JS to change the font. it is something like TextField1.fillcolor = "255, 255, 255"; (that changes the background fill to white). You can also replace fillcolor with font or border to change the color of the font or the border. I put a link to an Adobe website that goes over JS color changes below. You just need to add a PrePrint method for each field that you wish to remove the necessary highlighting on. Then once the user either hits a Print button that you have on the form or uses CTRL+P to print the form it will remove any highlighting.

Now On the Text Field not printing itself that I am not sure what you are asking for. Are you asking for the caption not to print or for there not to be a box around the data that is entered? If you do not want to have a box surround the text field that is in the Object section of the field (see image below). You just need to select None if you just want the text. If you want to change that with JS I put another link below that has the code to change the border color to white and the user cannot see it. If you do not want the caption to print the only method is to delete the caption from the text field and replace it with static text that can be hidden, but I am assuming that is not what you are talking about (correct me if I am wrong though).

Untitled.png

http://partners.adobe.com/public/developer/en/livecycle/designer/pdfs/ChangingFieldAndSubformBGColor...

https://forums.adobe.com/thread/1409617

View solution in original post

2 Replies

Avatar

Correct answer by
Level 4

Hello Teddy and wellcome to the group!

If you want to change fonts or other things then you might need to use the PrePrint method. What I normally do is select PrePrint from the "Show" section in the Script Editor (If you do not have it go to the toolbar at the top, Windows, and select Script Editor). After you select PrePrint you can now either type the name of the subform and field you want to change (or you can put your cursor in the Scripting Dialog box, hold CTRL and then select the field with your mouse) and then type in the JS to change the font. it is something like TextField1.fillcolor = "255, 255, 255"; (that changes the background fill to white). You can also replace fillcolor with font or border to change the color of the font or the border. I put a link to an Adobe website that goes over JS color changes below. You just need to add a PrePrint method for each field that you wish to remove the necessary highlighting on. Then once the user either hits a Print button that you have on the form or uses CTRL+P to print the form it will remove any highlighting.

Now On the Text Field not printing itself that I am not sure what you are asking for. Are you asking for the caption not to print or for there not to be a box around the data that is entered? If you do not want to have a box surround the text field that is in the Object section of the field (see image below). You just need to select None if you just want the text. If you want to change that with JS I put another link below that has the code to change the border color to white and the user cannot see it. If you do not want the caption to print the only method is to delete the caption from the text field and replace it with static text that can be hidden, but I am assuming that is not what you are talking about (correct me if I am wrong though).

Untitled.png

http://partners.adobe.com/public/developer/en/livecycle/designer/pdfs/ChangingFieldAndSubformBGColor...

https://forums.adobe.com/thread/1409617

Avatar

Former Community Member

Thanks so much for your help. That was exactly what I was looking for. Have a great day!