2 different text fields filled according to Drop down selection list

Hello

I am creating a form where a phone number is in a text box, an email address is filled and in another area of text, from a selection in a drop-down list. I use CS3.

Any help would be appreciated.

in the event from the drop-down list output put something like (in formcalc):

If ($.rawValue == 1) then

Phone number = '12345566. '

email = "[email protected]".

ElseIf ($.rawValue == 2) then

Phone number = "67890".

email = "[email protected]".

endif

(Make sure you have the ' specify values of element checked for the drop-down list object > link ")

Tags: Adobe LiveCycle

Similar Questions

  • Try to fill a text field of a zone drop-down list by using an 'if' statement

    I am filling a text field (modelT) with the text corisponding in the 'data' part of the selectedItem in the drop-down list box. The 'data' appears correctly when I use:

    modelT.text = event.target.selectedItem.data;

    But I'm calling it with an "if" (in red) and subsequently, I can dynamically fill the text field of the multiple drop-down list box. am I missing something simple, here is my code:

    Import fl.controls.ComboBox;
    Import fl.data.DataProvider;
    Import fl.managers.StyleManager;

    var cPurpose:Array = new Array)
    {label: "Execute task", data: "1"},
    {label: "Transportation equipment", data: "2"}
    );
    var purCb:ComboBox = new more;
    purCb.dropdownWidth = 260;
    purCb.width = 260;
    purCb.move (10, 300);
    purCb.prompt = "object of truck?
    purCb.dataProvider = new DataProvider (cPurpose);
    purCb.sortItemsOn ("label");
    purCb.addEventListener (Event.CHANGE, purchangeHandler);

    addChild (purCb);

    function purchangeHandler(event:Event):void {}
    trace ("Selected" + event.target.selectedItem.data);
    purT.text = event.target.selectedItem.label;
    purCb.selectedIndex = - 1;

    If (event.target.selectedItem.data == 1)
    {
    modelT.text = "T660"
    }
    If (event.target.selectedItem.data == 2)
    {
    modelT.text = "W900;
    }

    Thanks in advance for your help

    You must delete or move the following line so that it is not set to zero for the combobox control before trying to read what is selected:

    purCb.selectedIndex = - 1;

  • Try using the drop-down selection list but is a different

    Hi all

    ILO, at a loss, what I'm doing wrong here. Trying to change a field (previously in the textfield) a menu drop-down selection list. All works except one. Looks like a multidirectional selector, even if I put the type in the List select


    http://i.imgur.com/Hz7tP.PNG

    Had no idea of what I need to do to change from falling. Thank you very much.

    You set the height = 4 for the element. You're the problem.
    Make the height = 1.

    Kind regards

  • With the help of Interaction of the user as a drop-down selection list

    When my workflow running I want to select a host, then get my list of data warehouses available on this host of VcO

    I am able to create an array with the names of data warehouses (arry/String) but when I try to switch to an intervention of the user I am not able to populate a drop-down list with values of my table

    Can someone point me in the right direction

    Thank you

    Found the issue

    1. in the presentation definition defined a property 'list predefined elements.

    2. in field put a hashtag in front of the variable containing the array of strings

    example #valuesToSelect

  • Is there a way I can change the way fonts are presented in the drop-down selection list?

    In the font selection menu, the font name takes place, and the example called "sample" is low.  I can't tell what it looks like until I have type.  Is there a way to change the way in which it is presented?

    What version of Photoshop are you? with the current versions of CC, you can type your text and mouse on the list of fonts and it will change your typed text.

  • Text field - fill color

    I develop a form with a drop-down list and several text fields. Based on the user select on the drop down, other fields will change as mandatory or read-only

    To improve ease of use, I want to grey out those not required / only fields in reading.

    I'm doing it with the following script:

    this.resolveNode("textField1").fillColor = "195,195,195";

    However, legend and input area are gray out.

    Is there any script which will be gray on the box only?

    Hey Elvis Giff,

    Stefan cameron shared some good examples on this.

    http://Forms.stefcameron.com/2008/06/13/shading-the-caption-not-the-entire-field/

    http://Forms.stefcameron.com/2008/03/14/field-background-color-fill/

    Kind regards

    Rous

  • How to fill a field based on a menu drop-down select in another area?

    Here's what I'm trying to do:

    1 field is a drop down selection menu that requires a user make a mandatory selection that is in this case a list of apartment complexes. What I'm trying to accomplish, is once the user makes a selection in the drop-down list (field1) that it will fill the standard box 2 (txt) with the corresponding address of apartment complexes.

    So I seek Talan field 1 apartments, it could fill with Talan apartments address 2 field. I tried messing around with the calculation scripts, but I'm a fight lost here. Little help would be greatly appreciated!

    Hello

    Here's a sample: https://acrobat.com/#d=Hi0ZwVgVB1PWbxc6OJ0z4A where the script to the output of the drop event sets the value of the object of the address.

    Good luck

    Niall

  • fill in the text field with the caption for the radio list

    Hi, I'm looking for an answer to this all morning.  I need to use the value of a list of radio to populate a text field.  I can get the selected numeric value OK with

    $.rawValue = form1. #subform [0]. . Table3.Row1 #SubForm [0]. . RawValue location [0]

    but I want to get the text associated with the value element.  This could be the legend of the selected option button, since it is the same thing.  I don't want to use an if statement because I have a lot of forms to create and that would change things a few times in each shape.  How can I get the value of the text of the column of the item below?

    screenshot.17.png

    Try the following with two modifications to your hierarchy.

    (1) currently, you do not have a name for Page1. Make sure that you assign a name for ease of use. ("Page1").

    (2) define a name for the subform that contains PeriodRadio. ("Subform1").

    $.rawValue = form1. Page1. Table3.row2. Subform1. PeriodRadio.selectedMember (). caption.value.text.value;

    Thank you

    Srini

  • Drop-down selection w/export value sent to another field.

    Good afternoon

    I managed to create a drop-down menu field called Dropdown1 with a list of user names. Each user name has a value of unique export assigned to them.

    I then created a second text called Text1 field where the value of exports is complete. In this area, I've added the following script Adobe to send the value of exports of Dropdown1 successfully to Text1

    Event.Value = this.getField("Dropdown1").value;

    However, I need allow the user to make manual changes to both Dropdown1 and Text1 without the script of the substitution of manual entry. Is there a solution?

    Thank you!

    Ed

    I guess that's a custom calculation script. I think a better approach is to set the value of the text field when the user makes a selection in the drop-down list by using a script customized to the key sequence in the dropdown menu, something like:

    Custom keystroke for drop-down list script

    If (! event.willCommit) {}

    getField("Text1").value = event.changeEx;

    }

    Don't forget to delete the calculation script if you do this. In addition, it is best that you also set the option "Commit selected value immediately" for the drop-down list.

  • 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.

  • Select the customer name in a menu drop-down select or be able to type in

    Hello

    Is there a way to allow my users to have an option to select a customer name in a menu drop-down select or be able to kick it...

    Thanks in advance

    Hello

    I don't know about build Apex point of AutoComplete.
    But if you use jQuery UI to create the AutoComplete for the text element, you must limit not list user see all values.

    Kind regards
    Jari

  • Drop down the list with prices

    Hi all

    Is it possible to have five individual prices aligned on five drop-down selections for example

    Choice1 equals $49.95

    Lendemain2 "" $15.95

    Choice 3 "" $14.95

    Choice4 "" $13.95

    Choice5 "" $19.95

    So that when you select each choice the relevant price is displayed and these selections are calculated in the amount field, once the amounts are met.

    If so, someone could help me please.

    I started the first row of the fields without success

    I tried to download the form, but it is just sitting waiting

    Post edited by: ddownunder

    Examples work best for me so that why I always save the example and model files posted here and elsewhere.  So here's an expense report which I believe is exactly what you ask for.  Check the script slot, I've copied part of it here and I am sure that you will be able to understand.  In this case, the location of travel is the field drop-down list.

    -F.P1. TravelLocR1_0::exit - (JavaScript, client).

    Comment();

    refer to form fields

    var noMiles = this.getField ("NoMilesR1")

    is the value of exports, a key word?

    If (event.changeEx to gLocationMiles)

    noMiles.value = gLocationMiles [event.changeEx]

    -F.P1. TravelLocR1_0::change - (JavaScript, client).

    Comment();
    refer to form fields

    var noMiles = this.getField ("NoMilesR1")

    is the value of exports, a key word?

    If (event.changeEx to gLocationMiles)

    noMiles.value = gLocationMiles [event.changeEx]

    Each row grand totals

    -F.P1. TotalLineR1::calculate - (JavaScript, client).

    this.rawValue = xfa.form.F.P1.MileageAmtR1.rawValue + xfa.form.F.P1.hiddenSubtotalR1.rawValue;

    Then, there's a Total field at the bottom of the table

    -F.P1. TotalOfSubtotals::calculate - (JavaScript, client).

    this.rawValue = xfa.form.F.P1.TotAirCash.rawValue + xfa.form.F.P1.TotCarRental.rawValue + xfa.form.F.P1.TotCellPhone.rawValue + xfa.form.F.P1.TotCoCar.rawValue + xfa.form.F.P1.TotEmpMeals.rawValue + xfa.form.F.P1.TotLodging.rawValue + xfa.form.F.P1.TotMilAmt.rawValue + xfa.form.F.P1.TotPostage.rawValue;

  • Fill in the field of text based on the menu drop down.

    Here's the scenario: I have 2 drop-down lists on page 1 (list1, List2). Based on this selection, I want to fill in a text field on page 2 with their values, after clicking on a button to update at the bottom of page 2. I use the button click event, but how can I get the actual values of each drop-down list on the previous page?

    You must give the full path to the objects (i.e. form1. Page1.DDListName.RawValue). look in the view hierarchy to see the structure you want. Conversely, you can place the cursor in the script editor where you want the reference to appear, hold done the key ctrl and move the mouse to the object you wish to reference (it will change into a V). Then click on the mouse and the appropriate for this object reference is displayed in the script editor.

    Paul

  • How the auto fill a field based on the drop-down list unless the specific item is selected

    Hi all

    My apologies if I posted this in in the wrong place, but I am new to these forums, JavaScript and Adobe LiveCycle.

    I am trying to build a form using LiveCycle Acrobat but have problems with the drop-down lists.

    Inititaly I just wanted to fill in the fields in a table based on a matching menu selection dropdown in another table.

    I used the following code and it worked fine:

    Workbook.Content.Table1.Row3.AppropriationDetails.Row4.Cell1::change - (JavaScript, client)

    fFrom var = xfa.resolveNodes ("Workbook.Content.Table1.Row3.AppropriationDetails [*]. Row4.cell1');

    OTF var = xfa.resolveNodes ("Workbook.Content.Table2.Row3.AppropriationDetails [*]. Row4.cell1");

    for (var i = 0; i < = fFrom.length - 1; i ++) {}

    fTo.item (i) .rawValue = fFrom.item (i) .boundItem (xfa.event.newText);

    }

    The problem is that now I want the code above works UNLESS one of the items in the drop-down list is enabled specifically in this case, I want the text box in the other table to display a message such as "Details of the entry in the field below.

    I tried to create an If Else statement using the following code:

    Workbook.Content.Table1.Row3.AppropriationDetails.Row4.Cell1::change - (JavaScript, client)

    fFrom var = xfa.resolveNodes ("Workbook.Content.Table1.Row3.AppropriationDetails [*]. Row4.cell1');

    OTF var = xfa.resolveNodes ("Workbook.Content.Table2.Row3.AppropriationDetails [*]. Row4.cell1");

    for (var i = 0; i < = fFrom.length - 1; i ++) {}

    If (fFrom.item (i) .rawvalue = "Option 3") {}

    fTo.item (i) .rawValue = "enter the details in the field below.

    }

    else {}

    fTo.item (i) .rawValue = fFrom.item (i) .boundItem (xfa.event.newText);

    }

    }

    The code now filled the field with "Enter the details in the field below" any item I select in the drop-down list.

    Your help is greatly appreciated.

    See you soon,.

    ozzy_q

    Hello

    You use .rawValue in the change event. This will cause problems because the selection of the users has not received .rawValue from the drop-down list at the time when the change event is triggered.

    Move your script as it should to the output of the dropdown event.

    Hope that helps,

    Niall

  • Settlement of text with previous info in drop-down list fields

    Hello.

    I use acrobat 7... Create a PDF file to fill live

    The project cues the user with a drop down under the text field of everything everyone has ever typed in the before text box.

    How to stop the form of infill used previously info?

    Thank you

    Select "Edit > Preferences > forms > semi-automatic.

Maybe you are looking for