Hide text in the field when the drop-down list is selected

Hello, I am looking for a way to hide text in a text field when a number is from a drop-down list. For example, I have a table with text field that have a line pre-populated text in them. I would like the text to be deleted if 'Yes' is selected in a data entry drop-down list in the text box empty now.   Here's what I have so far:

If (this.rawValue == 'Yes') {SubStandard_A.StandardPkgTbl.Row1.TextField2.rawValue == ' ' ;}}

I tried .rawValue == "", .rawValue == null, .clearItems

Any help is greatly appreciated!

Hello

Just spotted your original script had a double == when assigning the value to the rawValue. You must use the double == equality test.

Here is a sample.

We hope that make you it work.

Niall

Tags: Adobe LiveCycle

Similar Questions

  • Hi, PDF form of the guru. How to make a text box become a required field IF a drop-down list is selected as the "Yes"?

    Hi, PDF form of the guru.

    How to make a text box becomes a "required field", IF a drop-down list is selected as the "Yes"?

    and 'not required' if the drop down menu selected as 'No' or left blank.

    Any help would be greatly appreciated

    see you soon

    Use this code in the custom drop-down list field validation script:

    this.getField("Text1").required = (event.value == "Yes");

    (Change "Text1" to the actual name of your text field, of course)

  • Search for text in the drop-down list when entering

    Hello

    When drop-down-list "allowing custom text entry" disabled and if there are for example values:

    one

    ABX

    ABY

    b

    c

    When the field has focus and the user types, the field then gets the first value that starts with the last letter typed.

    Is it possible to configure this feature for more respect then the first letter? While the user type "ab" and AR would have filled the "abx" value?

    There is no work around for it?

    Thanks for any help.

    Hello

    I don't think that there is an option to enable this behavior.  But I have implemented something a bit similar, see the example in this post http://forums.adobe.com/message/2372156#2372156

    Concerning

    Bruce

  • Hide several pages unless the drop-down list is selected

    Hello

    I have a 4-page form that I need to be able to hide 3 of 4 pages until a selection is made from a drop-down list on the first page box. So I have, for example, the pages marked:

    Page 1

    Page 2

    Page 3

    Page 4

    I have a drop down list which has

    Page 2

    Page 3

    Page 4

    for options and if no selection is made only Page 1, will be visible. If the selection is Page 2, I wish that all pages except page 2 to be hidden and only see page 2, did not 4 pages show and only show Page 2 fields.

    Does anyone know how to do this?

    Thanks in advance for any idea!

    The only downside to the activation of your condition is that the first page of the form can not be deleted. If you set page 1 "Hidden" will be hidden objects on the page, but the page itself will remain in the form that is displayed as a blank page.

    Attached shows a form with page 0-4 (5 pages). A drop down menu on page 0 and it controls the rendering of pages 1-4.

    Steve

  • change the text in the drop-down list

    Hello people

    I am newbie to script and get some difficulties to find the change script. I'm trying to add a drop-down list to add months in my script but it returns a complete list of months instead of a choice, please see the code of the fragment.

    var myMon;

    myDialog = app.dialogs.add var ({name: "Question Footer", canCancel:true});})

    with (dialogColumns.Add ())

    {with (borderPanels.Add ())}

    {
    staticTexts.add({staticLabel:"Months"});)
    }
    {
    myMon = dropdowns.add ({stringList:monthlist, selectedIndex:0});})

    }

    If (MyDialog.Show () == true) {}
    var myString;

    myString = myMon.stringList

    myDialog.destroy ();
    }

    Mac

    myString = monthList [myMon.selectedIndex];

    Substances

  • Enter text in the drop-down list LOV APEX 3.2

    I have several list of values that are used on oracle forms, we have created. Those who work large etc. They are all data in oracle tables.
    Users would like to be able to add to these tables if they enter data into a form that uses one of these list of values. They don't want to leave the form they are on and go to another form to enter data for the list of values.
    I didn't see any option to allow a user to enter new data in a drop-down list. I know it takes some effort, and I have to add code to my form to work.
    Unless I'm mistaken this doesn't seem to be a viable option at the Apex 3.2.

    Let me ask a few questions.

    1. it would be possible for me to simply add the link that says something like "my point is not listed.
    They click on it and it brings up a box pop up with a small form to add data to the table for the drop of LOV.
    After that is updated it then updates dynamically drop-down list on the main form.

    I am .net and VB.net guys only use apex 6 months here, so quite new for her.

    2. MAKE identical to this option, except instead of a link, I'll have a selection in the LOV
    who says that my article is not. Then if they choose this option it will bring up the box pop up with the form...

    3. If not these things are available in 3.2 available in apex 4.0?

    4. If they are 4.0 is easy to upgrade to 4.0 3.2 we have this on a Unix machine right now.

    5. all the best ideas?

    Thank you

    See anyway to do a popup window MODAL in APEX, using JavaScript

    Modal is a remnant of vs IE the thing in the world. Thus, the JS code goes something like this

    if (window.showModalDialog) {
    window.showModalDialog("f?p=&APP_ID.:&PAGE_ID.:&SESSION.:POP:NO:::","name","dialogWidth:600px;dialogHeight:400px");
    }
    else {
    window.open("f?p=&APP_ID.:&PAGE_ID.:&SESSION.:POP:NO:::","name","height=400,width=600,toolbar=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=no ,modal=yes");
    }
    

    Concerning

  • How to start the message with the drop-down list box selection?

    I'm trying to trigger a message box when I select 'No' as a selection of drop-down list by using the change event:

    If (this.rawValue = "No") {xfa.host.messageBox ("Please try again.", "Error")}

    However, it fires even when I select 'Yes.' Perhaps, it may be due to the fact that the following script is in the event "exit":

    If (this.) RawValue == null) {This.execValidate () ;}

    You have a syntax error. You want to change this.rawValue = 'No' to be this.rawValue == 'no '. In your script this.rawValue = 'No', you set the value of the field to be not so it will always be true in fact.

  • In Ver 4.0, what happened to the drop-down list of selections for the windows of the current tab?

    In previous versions of Firefox, in any tab open with multiple windows open, which is a search where you would go to a lot of different windows, there was a drop down to the right of the ' previous/next' button which would you allow to select before windows... and always the first. That's gone. It has been extremely helpful and I used frequently. Can add you it?

    You can get the menu drop-down by clicking on the previous/next buttons or now the left key pressed until the list is displayed.

    If you want the drop-down arrow, you can add it with the add-on of dropmarker rear - https://addons.mozilla.org/firefox/addon/backforward-dropmarker

  • When bookmarking a page, I get the full list of files in the drop-down list to select any folder in which the bookmark page. What you set for complete list of folders in the bookmarks falling?

    When bookmarking a page, I can not get the list of files to drop down to select any folder in which the bookmark page. The "folder:" bar was showing "Bookmarks Menu". The arrow on the bar descends 5 recent folders which pages were saved, but pop arrow to the right of the bar down opens just to show the three categories and the button "new folder". What you set for complete list of folders in the bookmarks falling?

    Start Firefox in Firefox to solve the issues in Safe Mode to check if one of your modules is causing your problem (switch to the DEFAULT theme: Tools > Modules > themes).

    See the extensions, themes and problems of hardware acceleration to resolve common troubleshooting Firefox problems and troubleshooting questions with plugins like Flash or Java to solve common Firefox problems

    See also http://kb.mozillazine.org/Bookmarks_history_and_toolbar_buttons_not_working_-_Firefox

  • Text in the drop-down list used in the report

    Hello

    I want to use in my report, the text of the index selected in the combobox. Unfortunately, the variable for a ComboBox is L1, not as text T1. So, when I want to insert text in the report, I cannot write @L1 @ because it appears in the index, not the text.

    For example

    ComboBox1

    0 Red 1 green 2 yellow

    and if I choose 1. Green

    I want to put 'green' as a text in my report. I can't call as a variable because the variable L1 is not text.

    How can I do this? Please

    Hi andrea11hr,

    You can use a table for the exchange of information. Please take a look at the attached example

    Greetings

    Walter

  • Best way to do the math based on the drop-down list box selections

    I've set up a timesheet that employees choose in two different drop-down fields which department they worked in and what station they worked at for each section start and end time. What I'm trying to do, is to have a summary table on the bottom of the timesheet which calculates the time spent for each combination.

    Timesheet snapshot.png

    Departments are N & S, P and so our stations are WN, ZO, LR and FM, the table would look like this:

    WN ZO LR FM
    N & S
    P
    A

    I have three sections of the hours of beginning and end with each of them their time in separate fields called M1, M2, and M3 calculation.  What I'm trying to implement is an if statement for each cell in the table. For example:

    If 'deptmonday1' = N & S and 'stationmonday1' = WN

    then x = M1

    and

    If 'deptmonday2' = N & S and 'stationmonday2' = WN

    then y = M2

    and

    If 'deptmonday3' = N & S and 'stationmonday3' = WN

    then z = M3

    If cell 'WNN & S' = x + y + z

    Can someone help me with the script for my if statements or y at - it an easier way to understand this? I use Acrobat Pro.

    Code custom for "WNN & S" calculation:

    var x = 0;

    var y = 0;

    var z = 0;

    If (this.getField("deptmonday1").value == "N & S" & this.getField("stationmonday1").value == "WN")

    x = Number (this.getField("M1").value);

    If (this.getField("deptmonday2").value == "N & S" & this.getField("stationmonday2").value == "WN")

    y = Number (this.getField("M2").value);

    If (this.getField("deptmonday3").value == "N & S" & this.getField("stationmonday3").value == "WN")

    z = Number (this.getField("M3").value);

    Event.value = x + y + z;

  • How to write Save function based on the drop-down list box selection data in app mxml flex4 with as3

    Hi all

    I'm working on the application web flex4 with as3.

    I have a doubt, I've created a mxml it has two text boxes, except the button and a combo box that is has two option as a percentage and the amount.

    my needs are I gave here.

    need 1: when I choose option amount that two text boxes does not have to be editable.when I select text tat box two percentage option will be editable.

    need 2: when I select the percentage in combox option and two text boxes are empty, and then click the button Save-> I want to display warning msg

    need 3: when I select the option amount combox and the two boxes are emptu click the button Save-> I don't want any warning messages.

    How to validate it and how to write backup for this function.

    This is my sample code:

    list box ID = baseAmtPer

    ID TextBox1 = maxCommAmt.text

    ID = baseAmtPer.text text box

    If (((baseAmtPer.editable!=true) & & (maxCommAmt.editable! = true)) & & ((baseAmtPer.text=="") & &(ma xCommAmt.text=="")) |) (baseAmtPer.text == "") | (maxCommAmt.Text=="")) -> This condition not allowing while I'm selecing amount in combo box. How the TWO TEXT BOX WILL BE EMPTY for this problem

    {

    Alert.Show ("enter in all areas", "Information");

    }

    on the other

    {

    some encodings

    }

    Hello

    Please go through the following Code:

    http://ns.Adobe.com/MXML/2009.

    xmlns:s = "library://ns.adobe.com/flex/spark".

    xmlns:MX = "library://ns.adobe.com/flex/mx" minWidth = "955" = "600" minHeight >

    Import mx.collections.ArrayCollection;

    Import mx.controls.Alert;

    Import spark.events.IndexChangeEvent;

    protected function button1_clickHandler(event:MouseEvent):void

    {

    If (comboBox.selectedItem == "Percentage" & textBox1.text == "" & textBox2.text == "") {}

    Alert.Show ("enter the values");

    }

    }

    protected function comboBox_changeHandler(event:IndexChangeEvent):void

    {

    {if(ComboBox.SelectedItem=="Amount")}

    textBox1.editable = false;

    textBox2.editable = false;

    }

    else {if(comboBox.selectedItem=="Percentage")

    textBox1.editable = true;

    textBox2.editable = true;

    }

    }

    ]]>

    Amount

    Percentage

    Thank you and best regards,

    ------------------------------------------------------------------------------------------ --

    Vibhuti Gosavi . [email protected] | www.infocepts.com

    ------------------------------------------------------------------------------------------ --

  • How do I automatically populate the text field box based on data generated automatically in the drop-down list?

    I created a drop down list which includes various regions.  When a region is selected it auto-renseigne another drop-down list with places.  I would like to automatically fill a text field with predetermined phone numbers when you have selected a location in the drop-down list of "places".  I want to integrate the phone numbers in the code, since the form will not access a database.  Any help would be greatly appreciated.  Thank you, Ed.

    Hello

    Here is the link to your form. https://Acrobat.com/#d=BaCL7BKKdAcgV3JIk61nZg

    You have the updated field matches in the event changes from the 2nd menu drop-down.

    While referencing you use .page1 while your page is Page1.

    Thank you.

    Sidonie.

  • I created a PDF form with several drop downs, all with the same drop-down values. When I select a value of 1 in the drop-down list fields, it breeds in all others - which I don't want. How can I fix?

    I created a PDF form with several drop downs, all with the same drop-down values. When I select a value of 1 in the drop-down list fields, it breeds in all others - which I don't want. Can I fix?

    I am fairly new to this, but I think it has to do with the way you have drop them downs named. Copy you a then keep stick in each area? If so, that's the problem. You must rename each with a different number: Dropdown1, Dropdown2, etc. I think this might solve the problem.

  • show/hide fields based on the drop-down list of choices

    I have a field from the drop-down list with three choices. Based on the selection, I need a specific text form field to appear and the others to stay hidden. (Or if it makes the code cleaner, the resulting field could be a drop-down list, too, with the selected choice.) I don't know Java well enough to extrapolate the code from the examples online and it fit my forms. I can provide an example of form. Thanks in advance for your help.

    There are ways to run this.  the easiest for you would be to add this script to the event (calculation of the Properties tab) to calculate the field that must be hidden.  Take notes, all "/ /" is some tips for you to understand the code.  You will need to put this script in all the areas you want to replicate the behavior, change the value depending on what you want to accomplish.  the word 'event' means myself to make you understand.

    If (this.getField("dropdown").value == 'put value here') {//replace "drop down" with the name of the drops}

    Event.Target.Display = display.visible;

    }

    else {}

    Event.Target.Display = display.hidden;

    }

    This works if you have a small amount of fields.  If you manage to have a large number of similar fields, let me know because there are other, faster ways.

Maybe you are looking for