Need help: I need a checkbox for auto fill a value defined in the separate text field.

Hi, this is my first time with the inclusion of scripts in a PDF form.

We have a form that requires the user to check a box on medical conditions, they have (e.g. asthma, diabetes, Hypertension).  Later in the form, you must type the same condition in a text box. (I know it's stupid to the double document, but it is necessary).  Y at - it a script that will automatically fill the text box when the check box?  For example, if they check the asthma, the text box on a page in the PDF file will say "Asthma, controlled."  Is this possible?

In addition, if they don't click asthma and click on diabetes, could you add diabetes to the first text box, but if they check them both, he would add asthma in box 1 and box 2 diabetes?

Any help would be GREATLY appreciated.

I'm using Acrobat 9

Thank you!

You could try to penetrate into this scipt in the text box that will contain the word 'Asthma', as appropriate.

The screenplay is based on the boxes with the names "cbAsthma" and "cbDiabetes".

The script in its present form adds the text in a box.

As always with these scripts, they are case-sensitive.

var a =' '

If (this.getField("cbAsthma").value is "Yes")
{
a = 'asthma (controlled).
}

If (this.getField("cbDiabetes").value is "Yes")
{
a = a + "Diabetes".
}

Event.Value = has

Hope that it will be somewhere near you looking for

Tags: Acrobat

Similar Questions

  • HELP - lost the button "calculate" in the "text field properties"! I try to summarize the total for separate text fields in a summary box.

    Help, please!  I try to summarize the total for separate text fields in a summary box, but have lost the tab 'calculate' in the 'text field properties area.  Any help would be greatly appreciated!

    When in forms editing mode (Tools > prepare form), select: more > return to the Acrobat form

    In the future, check the box 'this document requires signatures' when you choose at the beginning: Tools > form prepare

    unless you plan to use the form with eSign Document Adobe cloud service.

  • The drop-down menus, context menus and menu for Auto-filling items are not displayed!

    I FF4 beta, it started from FF4 beta 7. I'm working on Windows 7 ultimate 64-bit.

    The problem is that I can't see drop-down menus unless they have many elements, or context menus (such as highlighting a text then right click on it), auto fill bars no longer view AutoFill info is entered before... the menu itself appears a bit. but it is transparent and I can not display the items, do not know where to click to select the thing I want.

    I don't have this problem before 4.0b7... after I got it, I thought it was one of the plugins, so I disabled them all but still have the problem!

    A picture describing the problem encountered is taken here, now on this page, I've highlighted a text and right click on it: here you can see the menu appears somehow, surrounded by the red border, but I'm not!

    Tools > Options > advanced

    Under navigation try disabling use hardware acceleration when available. It shouldn't affect the context menus like this, but who knows with NVIDIA cards.

  • Please help me with the custom text field FormCalc

    There is someone online has done a very good thing for me - they helped me create a text field that would be of type 'this document has been printed on _' and include some day the pdf was printed on the employer's intranet site.

    I had a shortcut in my favorites and would click on it and place it on each new document that I needed on.

    Because the computer I was using suddenly fell down, can't get the details of how to set it up again. I have a pdf form that includes the box, but when I open it in LiveCycle, it's just empty.

    That's what I saved:

    < field h = mm "8,4935" name = "PrintedOn" w = "141,0398 mm" x = "-0,0001 mm" y = "0 mm" xmlns ="http://www.xfa.org/schema/xfa-template/2.5/" > ""
    < ui >
    < textEdit >
    < border hand = 'right' presence = "hidden" >
    <? templateDesigner styleId aped0? > < / border >
    < margin / >
    < / textEdit >
    < /UI >
    < police size = cast "18pt" = "Tahoma" weight = "bold" >
    < filling >
    < color value = "221,221,221" / >
    < / filling >
    < / make >
    < para hAlign = "center" vAlign = "middle" / >
    < link match = "none" / >
    < activity = "prePrint" ref = "$host" >
    < script >$ .rawValue = concat ("this document has been printed on:", num2date (date (), DateFmt (1))); < /script >
    < / event >
    < / field >

    I don't remember what to do to get this working.

    I use this text box "print on" ALL the time, and I need to know what to do to get back to work quickly.

    If there is someone who could help me, I could also send you a sample of a form which includes it - so you can see exactly what I mean.

    If someone could remember how to program this kind of thing in once again and save it in LiveCycle, then explain how I can put it on another computer so I'd really, REALLY appreciate it.

    ~ Chris

    PS - this one as I had put in place only prints print message per day on the first page. If she could somehow print on EACH page of the PDF file without me having to click and add it to each page individually, it would be better... but let's first!

    Hello

    The script is here. If you place a new textfield in the Master Page and put the following script in the event of pre-publication of the field:

    $ = concat("This document was printed on: ", num2date(date(), DateFmt(1)))
    

    The language is FormCalc.

    Please note that you don't need to go to the XML Source for this. Simply select the textfield object and open the Script Editor (in the Windows menu). Drag the bottom of the editor bar so that you can see a few lines, and then set the FormCalc language.

    Should work,

    Niall

  • Control values defined by the Index function only works for a running VI?

    I've never used set of control values based on the Index before so I decided to compare it against two other ways to set the controls on the front panel, by using the invoke Ctrl.Val.Set node and nodes for the value property. But if the VI which I am trying to set the controls does not work I get error 1000 say "The VI isn't in a State compatible with this operation." When I run the VI which I am trying to set the controls, I get an error. This is VI really only work if the VI is running? I can't set the values before calling the VI to run dynamically?

    I wonder why you do so in the first place.

    a bit of history. This feature was added to the problem write to items in front by reference is about 1000 times slower than writing to the Terminal. I think that this feature works by writing directly to the transfer buffer. It always ends up by being slower than writing to the Terminal, but only about 10 times slower.

    My company made use of this new feature. We needed it because we have updated thousands of values of frontage on the same VI by reference and labview couldn't keep it up (Yes, probably could have worked around him in a different way, but there is more detail than this...). If your ' e does not update thousands of articles, probably you should not use this feature. Performance savings is not worth the additional development effort it takes.

    It does not work probably because the transfer buffer does not exist when the vi is not running

  • Can someone help me with the properties of the multiline text field?

    Adobe is not my first or second language. I have been responsible for making a form to fill out and were able to understand a little after reading the Adobe Acrobat Bible, most, however, I just can't understand this little thing that's driving me crazy! I created a large default text field (so the person filling out the form to the management a little) this field is also defined as a multiline and also make field scroll long text. The problem is that the default text is highlighted not crept to crush then tab through the various areas of creation. He puts just the cursor at the end of the text by default so using back or manually select and delete text. I looked at how to set up the rest of the fields and the only thing different, I selected the multiline text box in the Properties menu. I need to be multiline text. If this is not the case, only the first words of the default paragraph I entered couple is visible. Any suggestions or ideas would be a step ahead of where I am now. Thanks in advance.

    Yesterday, we discussed a similar situation and the solution should work for you too: http://forums.adobe.com/thread/756410?tstart=0

    What you do is create a Format script that displays the text that you want, when the field is empty, but this text is not the value of the field. The modified script below prevents printing explanatory text if the field is empty.

  • Background color for the calculated text field

    Hello

    I have a text field which is calculated according to a formula that shows "RED" "GREEN" or "YELLOW".  I would like the field to automatically color itself based on such calculation.

    I tried to enter the following formula in the output * (JavaScript) events, but because the user is not really striking in the field, it will not work and the field remains white:

    VNAME var = this.somExpression;

    var fieldObj = xfa.resolveNode (VNAME + "#textEdit.border.fill.color .ui.");

    If (this.rawValue == "GREEN") {}

    fieldObj.value = "0,255,0;

    }

    ElseIf (this.rawValue == 'RED') {}

    fieldObj.value = "255,0,0";

    }

    ElseIf (this.rawValue == "YELLOW") {}

    fieldObj.value = "255,255,0;

    }

    else {}

    fieldObj.value = "255,255,255";

    }

    Any help is greatly appreciated!

    ~ Lisa

    Lisa,

    The code is supposed to be placed in the calculate event and not on the Exit event. Given that this field is read only the user never enters whatever it is in the field then the Exit event is meaningless.

    Here is the improved version of the calculate event code...

    Change the scripting language Java script and paste the code below into the event to Calculate the global field (RedYellowGreen1).

    Var score = TotalScore.rawValue;
    strColor var = "";

    If (Score == 0 |) Score == 1 | Score == 2)
    strColor = "GREEN";
    If (Score == 3 |) Score == 4 | Score == 5 | Score == 6 | Score == 7 | Score == 8 | Score == 9 | Score == 10 | Score == 11 | Score == 12 | Score is 13)
    strColor = 'YELLOW ';
    if(score>=14)
    strColor = "RED";

    Switch (strColor) {}
    case "GREEN":
    This.Border.Fill.Color.Value = "0,255,0;
    break;
    case "RED":
    This.Border.Fill.Color.Value = "255,0,0";
    break;
    case "YELLOW":
    This.Border.Fill.Color.Value = "255,255,0;
    break;
    }

    this.rawValue = strColor;

    Thank you

    Srini

  • How to set the background color for the HTML text field

    Hello

    Please don't me flame for this question is a bit off-topic. I would like to indicate to the end user that a field is mandatory. Using the name field * rating is good, but end users require a somewhat more tentative approach, they would like to have a light blue background for required fields.

    Is there a HTML attribute for the text fields to achieve? Thanks in advance.

    Tamas

    Hi Francine,.

    Try this

    Click your text box
    Select the ELEMENT property tab
    then choose the property attributes of HTML form elements give this code

    style = "" background: #0000FF ' "

    This will show the Textbox with blue background
    You can give any color by changing the #000000 to #FFFFFF

    Thank you
    Mark Wyatt

  • Looking for an example of "function that returns the error text.

    Environment: APEX 3.1.1.00.09 on AIX 5.3

    I'm looking for an example implementation of the posting of the "function that returns the error text.

    I would like to write a database function that does the validation logic and return the text of the error.

    Is it possible to create multiple lines of text of error based on error conditions?

    I'm trying to use it at the end of the input data to go on the set of the 'document' to the entry and highlight all error conditions encountered before the 'document' is subject to additional processing.

    I wrote the function and reference it in a posting as ' validate_stuff (: P3_DOC_SEQ); »

    I have an error message "validate_stuff is not a procedure or is not defined.

    The object is a function, not a procedure. It is defined to return a parameter VARCHAR2 hoped posting if it is not NULL.

    When I run the SQL function * more and spend in a number of documents are returned the correct error messages.

    Any direction is greatly appreciated.

    -gary

    Hi Gary,.

    You must RETURN the result of the function:

    BEGIN
     RETURN validate_stuff(:P3_DOC_SEQ);
    END;
    

    Andy

  • can someone help me? I need a script for Photoshop cs code 6, reflecting all the layers in a group, each individual layer, please!

    I need a script code that reflect each layer in a prayer group!

    Currently the command use the pivot point for the transformation on the right side of the Center, you can change this line:

    bcm_mirrorAllCH (getSelectedLayersIdx (), "CR", "Horizontal");

    with this:

    bcm_mirrorAllCH (getSelectedLayersIdx (), "CC", "Horizontal");

  • Help need a fix for my mobile menu is visible in the header at all times

    I have done some research and see you cannot pin a menu near the top of a mobile Web site, but is there a way to get around this? I have mobile pages long and find even though I have designing a headache to go back to the top. I need a way to have the menu at any time to my mobile site. Is there a work around that?

    Sorry, I downloaded that badly.

    You can download here:

    https://www.dropbox.com/s/hk9m8nk2zy7srxj/Aaron.Muse

    Thank you

    Sanjit

  • Need to update for Toshiba Bluetooth Manager V3 to use the Nokia phone

    Hello

    I use the bluetooth Toshia V3 Manager to start my USB2 bluetooth dongle.
    To be able to use my phone nokia with my computer, I need an update manager bluetooth V4 or V5.

    Who can help me?
    Cheers, S.

    I don't know how to help? Visit the Center of Information of BT and install the last stack of BT.

    I don't have a NOKIA phone but under how many resources you can find a useful document on the synchronization between your laptop and mobile phone NOKIA (NOKIA PC suite).

  • I m going in circles on this site from adobe.  I need to ask for a free upgrade to lightroom and the insturctions tap 'orders and "returns" which doesn't seem to exist.

    I just need the exact web address to request a free upgrade.  Why is it so difficult?  I've been circling on this web site for more an hour and the end upward to the same page before each time.

    Please tell me how to reach a real man live!

    Thank you for your response.  While I was posting here, I finally got a response to my question of the cat.  Chat and download a copy of my Bill, I was able to get a promise of an update to lightroom for 6 of 5.7.1 which I just bought.  I couldn't have lightroom to make recognition of face and then realized it was an old version.  Fortunately, but after 2 hours on the site, I managed to get a promise that the disc is mailed.  I never found my way around this hostile web site.  But now I can ignore it for awhile.  Thanks again for your response.

  • I need to send a document that can be populated in the drop-down fields that I created.  After the document is completed and signed I need the form must be blocked new changes

    I am needing help with someone either able to complete and sign a form in Reader I created in Adobe Acrobat Pro XI.  After that the document is a sign I need to be locked to new changes.  Can someone please

    Hi Suzette.

    Once the document is digitally signed it will no more allow changes.

    You can view the solution mentioned in the thread: Re: convert editable PDF read-only when the Envoy in an email - JavaScript

    Kind regards

    Rave

  • Can someone help me with a Code that allows you to hide all but the first few fields when the form opens

    My form has a section (subform) on top that is always open and then underneath it is dynamic and I want some subforms and sections to open based on users to input. I use action Builder to open the screen and have all the fields that are hidden, but I have too much subforms and must hide individually all subforms. Is there a code that allows you to hide all fields for me when the form opens, and then I can use action Builder to open just what I need based on a drop-down list button or radio?

    Thank you!

    Hello

    Using LockAllFields of Paul's example, you could place the JavaScript code within the root node docReady event (normally 'form1').

    Please note that the last line is the presence of one of the subforms to visible return. Let's call it ShowThisSubform.

    // Declare some variables
    var allChildElements;
    var intNumElements;
    var currentElement;
    var j;
    
    // Get all the child nodes of the parent element (the root node/"form1")
    allChildElements = this.nodes; // "this" will use the element where the script is placed
    
    //Total number of element in the object
    intNumElements = allChildElements.length;
    
    // Loop through all the child elements
    for (j=0; j< intNumElements; j++) {
         currentElement = allChildElements.item(j);
         // If the element is a subform we'll hide it
         if (allChildElements.item(j).className == "subform") {
              allChildElements.item(j).presence = "hidden";
         }
    }
    
    // Show one of the subforms
    ShowThisSubform.presence = "visible";
    

    Niall

Maybe you are looking for