Script of condition in the drop-down list

If the drop down menu 'A' is not, and the 'B' drop is

also no. 'C' becomes visible.

I need help with a script for this all I can get to is:

If

(xfa.event.newText == 'Yes') { }

Yes.presence

= "visible."

}

else {

Yes.presence

= 'invisible '.

}

and it does not work for this instance.

First of all, put values on the items in drop-down list in the 'Binding' palette 'subject: ' tab

As:

Yes bound value = 1

No has a bound value = 0.

Then,

Update on the event 'exit' on the two drop-down lists, then choose 'JavaScript' for script language:

//////////////////////////////

If (this.rawValue == "1" & B.rawValue == '1')

{

C.Presence = "visible";

}

on the other

{

C.Presence = "invisible";

}

//////////////////////////////

change the first line of refenence A.rawValue when you add this script in the drop-down list box B.

That should do it.

Good luck

Stephen

Tags: Adobe LiveCycle

Similar Questions

  • Problems with scripted patterns.  In the drop-down list, the trees do not appear and the box does not extend on the low side.

    I run Photoshop cc 2015, fully updated on a PC under windows 7

    Hi disable Question,

    The location of the tree models was changed to Filters > make > trees in Photoshop.

    Let us know if it helps.

    Concerning

    Sarika

  • SendTo shortcuts do not appear in the drop-down list sendto

    I just have to move on to Windows 7 and the drop-down list sendto does not work properly.  I have consulted the folder sendto successfully by the username C:\"Users\Your '\AppData\Roaming\Microsoft\Windows\SendTo.  There are shortcuts and standard destinations that are not appearing in the actual drop-down list.  The only destinations referenced when right click and access the sendto method are the disk of the user and a sendto folder that places the documents to the location C:\"Users\Your username"\AppData\Roaming\Microsoft\Windows\SendTo.

    Hello

    Make sure that you are logged on as administrator.

    Start - type in the area of research-> shell: SendTo
    Press enter

    Shell commands
    http://www.SevenForums.com/tutorials/4941-shell-command.html

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

    If necessary:

    You use professional, Ultimate, or Enterprise (part of a domain)
    where could be set in Group Policy (GPedit)? Antivirus/security, supposed
    refinement of public and other services could be the cause of the issue.

    Try to use a clean boot, and then check by removing and add a.

    How to troubleshoot a problem by performing a clean boot in Windows Vista or
    Windows 7
    http://support.Microsoft.com/kb/929135

    How to change, add or remove startup programs in Windows 7
    http://www.SevenForums.com/tutorials/1401-startup-programs-change.html

    Autoruns - free - see what programs are configured so that it starts automatically when your
    system boots and you log in. Autoruns is also the full list of registry and files
    locations where applications can configure start automatic settings.
    http://TechNet.Microsoft.com/en-us/sysinternals/bb963902.aspx
    ====================================================

    Other methods.

    1 follow these steps to remove corruption and damaged/missing system files that may have a role of repair or replacement, and it must be eliminated.

    Run DiskCleanup - start - all programs - Accessories - System Tools - Disk Cleanup

    Start - type in the search box - find command top - RIGHT CLICK – RUN AS ADMIN

    sfc/scannow

    How to fix the system files of Windows 7 with the System File Checker
    http://www.SevenForums.com/tutorials/1538-SFC-SCANNOW-Command-System-File-Checker.html

    Then run checkdisk (chkdsk).

    How to run check disk in Windows 7
    http://www.SevenForums.com/tutorials/433-disk-check.html

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

    2. troubleshooting questions Menu context (right click) are a process of eliminating exercise.

    Make a right-click is slow or weird behavior caused by context menus managers
    http://WindowsXP.MVPs.org/slowrightclick.htm
    and here:

    Manage the entries in the context menu for files, folders, disks, and objects in the Namespace
    http://WindowsXP.MVPs.org/context_folders.htm

    The ShellExView utility displays the details of shell extensions installed on your computer and allows
    easily disable you and enable each shell extension.
    http://www.NirSoft.NET/utils/shexview.html

    ShellMenuView is a small utility that displays the list of menu items which appeared in the context
    menu when you right click on a file/folder on Windows Explorer and allows you to easily disable unwanted
    menu items.
    http://www.NirSoft.NET/utils/shell_menu_view.html

    How to change or remove items from the right click Menu.
    http://www.WinVistaClub.com/E11.html

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

    If you have exhausted these try a repair Installation that allows you to
    keep the programs and data, although redundant backups are always a
    good idea. It is less likely to help you if you have not used the above
    methods such as the same parameters and conditions exist.

    I hope this helps.

    I hope this helps.

  • Selection in the drop-down list box determines the text to display in another box - ideas?

    Hello, my name is Zac.  I spent a lot of time trying to figure this one out for myself, but I couldn't find what I needed.  A few threads looked promising, but I realized that they only apply to the LiveCycle.  Many other threads link to discussion 2006 Thom Parker on this subject, but it is very advanced and I feel that what I need is not as complex as the solution he proposes.  I've never used Adobe Acrobat until a few weeks ago, but with the help of Bernd Alheit and George Johnson I managed to create a document with fly-out help windows and scrolling lists and radio buttons which dictate the choice.  It's great and it works.  The last thing I have to do is to create a text box (or some kind of box) which will display a pre-written block of text based on the user choice in another area (a drop-down list box).  Like this:

    image for forums 2.PNG

    I wish, it is also easy to create because it draw a picture of him!  If the user selects "Algebra 1", for example, a specific description display below.  There are a lot of courses and descriptions, and the descriptions are long enough (as shown).  It is not necessary for the user to make changes to the description - in fact, which would be terrible.  But I would like to be able to copy text from it and paste the text in another area of text on the same page.

    Thank you very much, all those who have ideas please share them! Again wild guesses. I learn from all this.

    -Zac

    This involves using a script. If you want to write the code yourself read this tutorial:

    https://acrobatusers.com/tutorials/change_another_field

    If you don't feel like messing around with the code, you can use this tool that I developed to easily set up with the help of an input file:

    Scripts custom Adobe: Acrobat - fill the drop-down list

  • Defining form fields such as required based on the entry in the drop-down list

    I'm trying to set the properties of a few form fields as required in the case of a specific value is selected from a drop-down list.

    I entered the code of the tab actions from the drop-down list properties below > mouse down > run a java script. The problem is that it works only if I come out and enter again the drop-down list. "I tried to invoke the code with"Mouse down","Mouse entry", out of the mouse ' none of them worked unless I go out and again the drop-down list.

    Any suggestions?

    Thank you!

    var devused is this.getField ("device");.

    var comptype is this.getField ("Type of complaint");.

    var proname = this.getField ("product name");

    var feels = this.getField ("sent to the sponsor");

    If (comptype.value == 'Associated Product complaint') {}

    devused. Required = true;

    proname. Required = true;

    smells. Required = true;

    }

    else {}

    devused. Required = false;

    proname. Required = false;

    smells. Required = false;

    }

    What you describe is the way documented in what forms Acrobat and Acrobat JS behave by Form Event Processing

    For your described form, we can use a custom format for the field drop-down list script:

    If (event.willCommit! = true & event.changeEx! = "")
    {
    var devused = this.getField ("device");
    var proname = this.getField ("product name");
    Envoy of var = this.getField ("sent to the sponsor");
    Switch (Event.changeEx)
    {
    case "related product": complaint
    devused. Required = true;
    proname. Required = true;
    smells. Required = true;
    break; Go at the end of the switch;
    Repeat fdor each value of the option in the drop-down list.
    by default:
    If no match for the above cases, it is found;
    devused. Required = false;
    proname. Required = false;
    smells. Required = false;
    break;
    } / / end of switch event.changeEx;
    } / / end not true willCommit;

    You must set the ' Commit selected value immediately "and as one moves upwards or downwards the options, the related fields will change and stay together when you exit the field note that the field name is not used in the script because the field is the event object until it leaves the field.

  • Acrobat Pro XI - import Pdf when you use the drop-down list

    Hello Adobe community,

    WARNING: Newbie here

    I am trying to import an existing pdf, after that the user has selected an item in the drop-down list. For example; I have a form with a menu drop-down and three points on the list (caustic diesel, heavy and hydrocarbons). Each item in the list has its own PDF which must to be imported into the document if selected. Once the user has selected in the list, I need to import a pdf file into the existing document. I did some basic research, but can find no chance.

    Any tips or tutorials that I can search will be appreciated.

    Thank you

    Again, it is delicate. You can show/hide entire pages to convert them into models and by changing the value of their hidden property, but this only works in Acrobat. In Reader, you will need to convert the model pages, hide them and then use a script to spawn them when you want to show them and then delete them when you want to hide once more. Possible, but not easy to implement.

  • Automatically populate a drop-down list by using another selection from the drop-down list box

    New java/preparation forms so I apologize in advance.

    I currently have a menu drop-down box 1 (Occupation) with three options: "enter your own description/blank", retired housewife. When someone chooses either retirement or anyone at home, I would another drop box 2 (employer) to assign automatically "n/a. . The employer drop box has only two options: "enter your own/blank", N/A.

    Far, I could for that box to fill but only when the person clicks in the box (as if they were about to enter their own text.) Then only it will fill the drop-down list "employer." I would like it auto fill once the person has chosen retired, Virgin or stay-at-home woman without having to enter in the box (just using the arrow to the size of the drop-down list box).

    I currently have a key shot that resets the employer box when a person chooses the option vacuum/enter your own option. I then a JavaScript (only for the housewife now) that only works if you click the box of. Key combination works I want to than the other options work as well. If the client settles on white, the choice of the employer updates automatically empty without having to click in the box of. Any help (including general advice to make my code cleaner) is very appreciated!

    Current script of typing:

    If {(event.willCommit)

    If (event.value == "") this.resetForm (["use"]); of other SetFieldValues (event.value);

    }

    The current upward, mice running JavaScript :

    var v = this.getField ("Occupation") .value

    If (v is "Housewife")

    1. this.getField("Employer").value = "N/a".

    I think maybe I should use event.willCommit in my formula, but I'm not sure how to include it.

    Thank you!

    I would not use the key sequence or MouseUp actions for this, but the action post.

    Just make sure that you set the field option to validate the selected value immediately (under Properties - Options) and then use this code as the custom validation script:

    var employerField = this.getField("Employer");
    if (event.value=="Homemaker" || event.value=="Retired")
        employerField.value = "N/A";
    else employerField.value = employerField.defaultValue;
    
  • Display the export value of the drop-down list instead of the element

    I'm showing the value to the export of a drop-down list instead of the selected option or the user selects BLACK, but the value of exports of BLK is actually displayed.  I can find many discussions on how to get the value of the exports and display it or use it to trigger another answer in another area and I can usually tweak my existing JavaScripts when I need something new, but I just can't wrap my head around this!

    This is my last attempt (failed)

    var f = this.getField ("eyes");

    If (event.value is 'Black - BLK')

    f.Value = "BLK".

    I use Acrobat PRO DC.

    Any help is appreciated,

    Thank you

    Xavier


    I've been doing this for a long time and have never heard of anyone who wants something like this, so it is interesting. Remove your current script and try the following script Format customized drop eyes:

    Custom drop-down list Format script

    Event.Value = event.target.getItemAt (event.target.currentValueIndices, true);

    This defines what is displayed in the drop-down list in the value of exports of the selected item. Select the 'Value selected to validate immediately' option to the drop-down list for smoother operation.

  • Is this possible? Subforms appeal based on the drop-down list associated with the database

    I'm hoping to make a dynamic shape and I wonder if it's possible.

    I have a database with about 300 entries - pieces of agricultural goods and a few little bits of info on each of these properties. I want to create a form where users can choose the piece there rather than the property in a drop-down list. Based on the property they select, another menu drop down to fill with the cultures associated with this property. Then based on the selection made in this drop-down list, a specific form will be brought upward.

    For example, a person selects property #102 in the drop-down list. In the database, property #102 is associated with wheat, barley and corn, so the next drop would be complete with these three cultures. The user selects the wheat in the drop-down list and the form of wheat would be called. 

    I hope I explained that well enough.

    Is this possible? And if it's possible, how complicated to do? Assuming that I already have the database and subforms, it would be a long process from weeks to the script, or it would be simple enough?

    Yes, this could be done, here is an example that should help: Drop dependent dropdown (specimen attached)

    On the basis of selection (change event of the second menu drop-down), you can show or hide a subform.

    -Wasil

  • How can I view the swatches.everyItem in the drop-down list

    Hello world

    Can you fix my script, are intended to let the swatches.everyItem in the drop-down list

    If (app.selection.length > 0 & & (app.selection [0].constructor.name == 'Cell' | app.selection [0].constructor.name == 'Table')) {}
    If (app.scriptPreferences.version > = 6) {}
    app.doScript (principal, ScriptLanguage.JAVASCRIPT, [], UndoModes.ENTIRE_SCRIPT, "style every second column in the selection");
    }
    else {}
    main();
    }
    } else {}
    Alert ("nothing or wrong selection!');
    }

    //---------------------------------------------------------------------------------------- --------------has some prolems in this part


    var sN = doc.swatches.everyItem () .name,
    sID = doc.swatches.everyItem (user.user),

    main() {} function

    var l, c = 0, o, p, pO = {}, pA = [];
    If (s == null) {alert ("selected No. Swatch"); return ;};}               I want to show swatches.everyItem.name as myColor
    s = doc.swatches.itemByID (sID [s.index]);

    //---------------------------------------------------------------------------------------- --------------has some prolems in this part


    var myFillTint = 20;
    var myCharStyleName = "Bold";
    var myStrokeWeight = 0.5;

    var curSel = app.selection [0];
    var allCells = curSel.cells;
    var startCol = curSel.cells [0].name.split (":") [0] * 1;
    var endCol = curSel.cells [-1].name.split (":") [0] * 1;
    var curSel.cells = StartRowOptional [0].name.split (":") [1] * 1;
    var EndRowOptional = curSel.cells [-1].name.split (":") [1] * 1;
    var counter = 1 + startCol;

    for (var i = 0; i < allCells.length; i ++) {}
    var curCell = allCells [i];
    var curCol = curCell.name.split(":") [0] * 1;
    curRow = curCell.name.split(":") var [1] * 1;

    If (curCol, counter)) {}
    with (curCell) {}
    fillColor = myColor;
    fillTint = myFillTint;
    text [0] .appliedCharacterStyle = myCharStyleName;
    rightEdgeStrokeWeight = myStrokeWeight;
    rightEdgeStrokeColor = myColor;
    leftEdgeStrokeWeight = myStrokeWeight;
    leftEdgeStrokeColor = myColor;
    }
    If (curRow == StartRowOptional) {}
    curCell.topEdgeStrokeWeight = myStrokeWeight;
    myColor curCell.topEdgeStrokeColor =;
    }
    ElseIf (curRow == EndRowOptional) {}
    curCell.bottomEdgeStrokeWeight = myStrokeWeight;
    myColor curCell.bottomEdgeStrokeColor =;
    }

    Counter = counter + 2;
    }

    If (counter > endCol) {}
    counter = 1 + startCol;
    } / / end if
    } / / end for
    } / / main end

    John

    Check the names of var and share the same version:

    mColor vs myColor

    mCharStyleName vs myCharStyleName

    (will use you a dropDownList 2nd as well?)

    Note that I'm just show the way. I'm not an end_product_supplier.

    Jarek

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

  • Simple javascript for the drop-down list IF, fills two different fields

    I don't write js, but can grasp what it did when I hang a sample edit and re - purpose. I have a form simple fax that already resets to the opening. Here's what I'm doing:

    User selects the sender's name in the drop-down list of about 15 (grow w / hour)

    Fill in the following text field "sender Fax #" with the number of direct fax (xxx-xxx-xxxx in the js) user

    Are also complete this later text field "sender Ph #" with the number of direct ph of the user (xxx-xxx-xxxx in the js)

    Here is an example which I believe works the way you want: https://workspaces.acrobat.com/?d=gZNDS8dQQNqvwocUufXHNQ

    You have to watch the fields to see how they are implemented and to study different scripts to see how it works. If you have any questions, post again.

  • Get the value of the drop-down list (selectedIndex) and the text field - does not

    Hi all

    I'm trying to find and change the values selected by the user using a drop-down list and text field. Here's the code.

    ChangeRevDetails();
    function ChangeRevDetails(){
    
    
              var myDialog = app.dialogs.add({name:"Enter copyright information"});
    
    
    //    var monthlist = col1.dropdowns.add('myList', undefined, myList);
    
    
              var col1 = myDialog.dialogColumns.add();
              var col2 = myDialog.dialogColumns.add();
      
        col1.staticTexts.add({staticLabel:"Month:"});
              col1.staticTexts.add({staticLabel:"Year:"});
        col1.staticTexts.add({staticLabel:"Rev. no.:"});
        
        var myList = [ "January", "February",  "March", "April", "March", "April", "May", "June", "July", "August", "Sepetember", "October", "November", "December" ];
    
    
         var myMonth = col2.dropdowns.add({stringList:myList, selectedIndex:0, minWidth:100});//{minWidth:100});
         var myYear = col2.textEditboxes.add({editContents:"2013", minWidth:100});   
         var MyRev = col2.textEditboxes.add({minWidth:100});
    
    
        var RevMonth = (myList [myMonth.selectedIndex]);
        var RevYear = myYear.editContents;
        var RevNumber = MyRev.editContents;
        var RevToReplace1 = RevMonth +", "+ RevYear;
        var RevToReplace2 = RevMonth +", "+ RevYear + " Rev. " + RevNumber;
    
    
        var myResult = myDialog.show();
    
    
            if(myYear.editContents == "") //entry is "" 
            { 
            alert("Please enter some text into the contents field."); 
            ChangeRevDetails(); 
            }
            else if(myResult == true) //user entered datas 
            { 
    
    
                alert (RevMonth);
                alert (RevYear);
                alert (RevNumber);
                alert (RevToReplace1);
                alert (RevToReplace2);
    
    
                app.findGrepPreferences = NothingEnum.nothing;
                app.changeGrepPreferences = NothingEnum.nothing;
    
    
                // grep find/change
                app.findGrepPreferences = app.changeGrepPreferences = null;       
                app.findGrepPreferences.findWhat = "[\\l\\u]+?\\s?\\d{4},?\\s+[\\l\\u]+\\.*\\s+\\d+";
                app.findGrepPreferences.appliedParagraphStyle = app.activeDocument.paragraphStyleGroups.item("Back page"). paragraphStyles.item("Legal_7/9");
                app.changeGrepPreferences.changeTo = RevToReplace1;
                app.changeGrepPreferences.appliedParagraphStyle = app.activeDocument.paragraphStyleGroups.item("Back page"). paragraphStyles.item("Legal_7/9");
                app.activeDocument.changeGrep();
    
    
                app.findGrepPreferences = NothingEnum.nothing;
                app.changeGrepPreferences = NothingEnum.nothing;
      
        } 
        else //implies user clicked cancel 
        { 
        myDialog.destroy(); 
        }
    
    
    }
    
    

    The problem is, it does not take the value that the user selects in the drop-down list and the text field. It takes the default value as "January" and the year is '2013' as these two values are given as selectedIndex:0 and editContents: "2013". I compared the coding with a few other scripts work as well, but it does not work. I added several alert boxes to check the value we get.

    In addition, search for it and change also does not work. Please help me on this. Thank you.

    Kind regards

    Bachi. D

    Change the order of dialogresults:

    ...

    var myYear = col2.textEditboxes.add ({editContents: "2013", minWidth:100});})
    var MyRev = col2.textEditboxes.add({minWidth:100});)
    Ditto var = myDialog.show ();
        If (myYear.editContents == "") //entry is «»
        {
        Alert ("Please enter a text in the content field.");
        ChangeRevDetails();
        }
        else //user entered if(myResult == true) datas
        {
    var RevMonth = (myList [myMonth.selectedIndex]);
    var RevYear = myYear.editContents;
    var RevNumber = MyRev.editContents;
    "var RevToReplace1 = RevMonth + ', '+ RevYear;

    "var RevToReplace2 = RevMonth + ', '+ RevYear + 'Rev' + RevNumber;

    ...

    did not have a look for the problem of change to find

  • Criterion from the drop-down list value null | " "

    I wrote a script to sign before testing a value in a drop-down list before allowing the signing of the document. However, I want to test a null plus a space aka "". "" I added a value in the drop-down list of "" as well as the choice of names for users could erase an accidental in this list selection before they were ready. However when I place the operator (|) in the case or statement of the script, the script does not work. If I remove the | "" declaration the script works as it is supposed to. " How to test for this value of "" as well as the test null so I don't have to write a further statement?

    If (form1. Page3.author.reviewed.admin.RawValue == null | " ")

    {

    xfa.event.cancelAction = 1

    xfa.host.messageBox ("you have not selected your name on the drop-down list before trying to sign the document.");

    }

    on the other

    {}

    ;

    If the declaration is incomplete. You need to test again for the other value:

    If (form1. Page3.author.reviewed.admin.RawValue == null | Form1. Page3.author.reviewed.admin.RawValue == "") ""

  • Reg - key event "F1" in the drop-down list box

    Hello

    Requirement:

    I need that to launch a browser window press the 'F1' key during the video (swf) has the focus. I did and it works very well for me in the web application.

    Problem statement:

    When a film was released and with focus in "Combo" (which has the list of items begins with A letter Z) control then, I pressed the 'F1' key but the browser window has been launched, instead "main action from the drop-down list box event fired and the article begins with the letter 'P' has been selected in the combo box." So now again once I hit 'F1', the browser window launched according to my condition.

    This behavior occurs whenever launched film has the focus in the "combo box"; otherwise, if the focus is on another control as TextInput etc, no problem for me. A more information, if the drop-down list box is not no matter what element does begin with the letter 'P' so no problem for me.

    I tried to understand the behavior of the combo, but again, I have no idea. Please share your knowledge/thoughts.

    Environment:

    Flex builder 3.5

    11.2 Adobe flash player

    Windows XP SP3

    Kind regards

    Mani

    Hello

    I just replaced Manager keydown to the ComboBox component to avoid his own behaviour of spread of events if the 'F1' key and his works fine for me.

    Thanks for all,

    -Mani

Maybe you are looking for

  • Satellite A30 monitor shows no sign of life

    Hellomy monitor shows no sign of life even if the rest of the computer (HD lights etc) lights up. Help.

  • Power Manager BUG?

    Hi people; I have a x130e on Windows 7 (x 64) with Power Manager installed 6.68.8 with the Lenovo Power Management driver (from the same package). What I see is that the always on function USB does not work. It is enabled in the BIOS and enabled in t

  • Monitor goes blank after windows XP starts.

    After my computer Windows XP starts, the screen turns white.  I can see typical splash screens and the windows icon, that my home screen.  But shortly after so that files are always load, the monitor is going gray.  It is still 'active' designated by

  • Problems with ImageAssist on the machines using SSDS m2 (NOT is)

    Hello guys,. first of all, I must admit, I am facing ImageAssist the first time, so maybe I m ask stupid or boring. I tried the search within this Forum, but didn t get results... Okay, so here´s I want to do... our new generation of material (E7270,

  • I have Annoying problem, I can hear the sound of the headphones and portable speakers...?

    I recently bought (Dell inspiron 3537), windows 7 64-bit (6.1 build 7601), more info on first image,. http://i.imgur.com/SBEezVe.PNG but I have a problem when I have a headphones connection to the laptop... the headset works well, BUT I can hear the