• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Set Radio Button border color to transparent SaveAs

Explorer ,
Aug 04, 2017 Aug 04, 2017

Copy link to clipboard

Copied

Creating Forms using Adobe Acrobat Pro 11

Forms will be run using Adobe Reader 11

I have a Form with some textfields and radio buttons.

Where I have used the border colors of each to "highlight" what should be filled in by the user.

But when the user hits a Submit button (which will saveAs), I want the border colors to change to white so on the final saveAs'ed document the textfields and radio buttons look "flat".

I have the javascript to change the border color of the textfields to white before I saveAs the form.

===========================================================

// Set Border Colors to White for all TextFields properties

for (var i = 0; i < vdoc.numFields; i++) {

                // Get a reference to the current field

                var f = vdoc.getField(vdoc.getNthFieldName(i));

                // If the field is a text field, set these properties to these values

                if (f && f.type === "text") {

                    f.textFont = font.Helv;  // Helvetica

                    f.textSize = 0;  // 0 = Auto

                    f.alignment = "center";

                   

                    // No Border Color

                    f.strokeColor = color.transparent;

===========================================================

How do I change the border color of the radio buttons to transparent also before I complete the saveAs function?

Thank you...

TOPICS
PDF forms

Views

2.0K

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Community Expert , Aug 06, 2017 Aug 06, 2017

Try this:

  if (f && f.type == "radiobutton") {

     f.strokeColor = color.transparent;

  }

Votes

Translate

Translate
Community Expert ,
Aug 06, 2017 Aug 06, 2017

Copy link to clipboard

Copied

Try this:

  if (f && f.type == "radiobutton") {

     f.strokeColor = color.transparent;

  }

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Aug 07, 2017 Aug 07, 2017

Copy link to clipboard

Copied

LATEST

That worked great, thank you.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines