Make subform visible by making a selection in a dropdown

I am trying to make a subform visible if the user select yes from a dropdown.
I have the following setup on the form
Subfom1 -Dropdown with 3 entries, Select, No Yes.
Subform2 – Text field for users to enter test
The code I have been trying to use is
“execEvent("change"); In the Initialize event and in the change event I was using
if (xfa.event.change == "5") {
    subform2.presence = "visible";
When I try the form, nothing happens,. There is no errors in the Javascript debugger
Any ideas would be helpful.
I am running Adobe LiveCycle Designer 8.05.2073.1.374024
Any ideas would be helpful
Chomp

Thanks Robert;
I did as you suggested and I still cannot get the field to become visible. I tried a couple of things.
(1) In the Initialize Event - execEvent("change");
In the Change Event - if (this.rawValue == "1") {
why_subform.presence = "visible";
The subform did not become visible nor was there an error in the javascript debugger
(2) Took execEvent("change"); out of the Initialize Event.
In the Change Event - if (this.rawValue == "1") {
why_subform.presence = "visible";
The subform did not become visible nor was there an error in the javascript debugger
Initialize Event blank
Added to the Change Event
if (this.rawValue == "1") {
    why_subform.presence = "hidden";
if (this.rawValue == "2") {
    why_subform.presence = "visible";
The subform did not become visible nor was there an error in the javascript debugger
(3) Added execEvent("change"); to the Initialize Event
The subform did not become visible nor was there an error in the javascript debugger
Preference defaults are set to – Preview = Interactive Form
                                                 XDP Preview Format – Adobe 8 (Dynamic) XML Form

Similar Messages

  • Make subform visible, content doesn't show

    I have a script that's supposed to make subforms visible based on the selection in 3 DDLs. The script seems to work sort of. The space is there but the actual content of the subform is not visible.
    The subforms are set to Hidden.
    The script is set in the exit event of the third DDL.
    Thanks,
    MDawn

    Hi Margaret,
    In the windsNtwkAccess exit event code at line 298  you need to change
    else if (v1 = '2')
         to
    else if (v1 == '2')
    That is change the equals to a double equals.
    You also have code in the form1.page4.eitEquipment ready:layout event and form1.page4 ready:layout events that seem to duplicate this code and should be removed.
    Regards
    Bruce

  • Button makes subform visible, then adds another instance

    Hello,
    I have a button which makes a subform visible. That is working fine.
    I'd like the button when clicked a second time to add another instance of the same subform. Is this possible? I have no idea how to begin with the JavaScript for this and would appreciate help.
    Thanks in advance,
    MDawn

    Instead of making the subform visible and then adding instances you can do it just using instances then the button is doing the same thing.
    To "hide" the subform using instances, make sure under Binding that the Min Count is clicked off and the Inititial Count is set to 0 (zero) - your subform will now be hidden by default.
    Change the code you have showing the subform to use addInstance() instead of presence, using the underscore shortcut for the Instance Manager (you have to use the underscore method because the instance doesn't exist yet):
    _hiddenSubform.addInstance(true);
    If you remove instances back to zero then the subform will go away again. Doing it this way also has the advantage of resetting all the data in the subform.

  • Dropdown selection to make a subform visible

    Hi I am trying to work out how to make a subform visible/invisible dependant on the selection made in a previous dropdown box. Any ideas?

    Add the following javsscript code in the change event:
    var selection = xfa.event.newText;
    if(selection == "visible"){
    subform.presence = "visible"
    else {
    subform.presence = "hidden"

  • Makeing subforms visible depending on what is selected from the dropdown

    Good day all;
    Looks like I am batting “0” today. For some reason I am not able to get a number of things to work today… Maybe I should just write this day off as a loss..;>))
    Any way; I am trying, without success to get sub forms to become visible depending on what is selected from a dropdown. I have tried using “switch” (see below) but I end up getting the famous “Syntax” error.
    I have also tried an “if” (see below) statement, but that did not seem to work either.
    What I would like to have happen is when a user selects 1 of 2 choices 1 of 2 sub forms becomes visible.
    As well, if the user has initially selected the wrong dropdown and they select now select the correct one, I would like the incorrect sub form to become invisible again.
    I would appreciate any help
    switch (this.rawValue)
        case "2":
        staffing_inter.presence = "visible";
    else
    staffing_inter.presence = "hidden";
        break;
    IF statement
    if(this.rawValue = 2 )
        staffing_inter.presence = "visible"
    else{
    staffing_inter.presence = "hidden";

    Thank you Jono and Niall;
    I was looking through the forum and found a post by Niall that appears to be working; I was wondering if this should be used or the one that Jono has posted...
    staffing_inter.presence = "hidden";
    staffing_inter.preAsence = "hidden";
    // Then show the appropriate one
    if (this.rawValue == "2") {
    staffing_inter.presence = "visible";
    else if (this.rawValue == "3") {
        staffing_exter.presence = "visible";

  • Problem with a script making subform visible

    Hello
    I have a form with 5 radio buttons. Two of the radio buttons, values 3 and 5 need to make a hidden subform visible. All other values leave the subform hidden. Here is my script:
    if (this.rawValue == '1') {
    page1.deliveryInformation.flowed.presence = "hidden";
    if (this.rawValue == '2') {
    page1.deliveryInformation.flowed.presence = "hidden";
    if (this.rawValue == '3') {
    page1.deliveryInformation.flowed.presence = "visible";
    if (this.rawValue == '4') {
    page1.deliveryInformation.flowed.presence = "hidden";
    if (this.rawValue == '5') {
    page1.deliveryInformation.flowed.presence = "visible";
    else {
    page1.deliveryInformation.flowed.presence = "hidden";
    Value 3 is not working. All other values work as expected. I've been looking at this script for over an hour and can't figure out why it isn't working. Any help would be appreciated.
    Thanks,
    MDawn

    The issue is with the last else part.
    Either place the conditions in
         if(){
         elseif(){
         else{
    OR
    use the switch case as below.
    switch (this.rawValue)
    case "1":
    page1.deliveryInformation.flowed.presence = "hidden";
    break;
    case "2":
    page1.deliveryInformation.flowed.presence = "hidden";
    break;
    case "3":
    page1.deliveryInformation.flowed.presence = "visible";
    break;
    case "4":
    page1.deliveryInformation.flowed.presence = "hidden";
    break;
    case "5":
    page1.deliveryInformation.flowed.presence = "visible";
    break;
    default:
    page1.deliveryInformation.flowed.presence = "hidden";
    Thanks
    Srini

  • Make Table visible after button is clicked

    Hi,
    How to make a table visible only after a button is clicked on the screen?
    I have two input fields and based on that data we click a search button and data is displayed.
    How to make the table  visible only after the button is clicked.
    Regrads

    hi ,
    u proceed as follows :
    1 bind visible property ur table to a context attribute of type wdui_visibility
    2 set the default value to '01' , making it '01 ' means initially ur UI wud be invisible
    3 in the onActionEvent method , when button is clicked , read the context attribute
    4 set its value to '02' using set_attribute method , u can do it using code wizard
    DATA lo_nd_cn_all TYPE REF TO if_wd_context_node.
         DATA lo_el_cn_all TYPE REF TO if_wd_context_element.
         DATA ls_cn_all TYPE wd_this->element_cn_all.
         DATA lv_invisible LIKE ls_cn_all-invisible.
    *    navigate from <CONTEXT> to <CN_ALL> via lead selection
         lo_nd_cn_all = wd_context->get_child_node(
         name = wd_this->wdctx_cn_all ).
    *    get element via lead selection
         lo_el_cn_all = lo_nd_cn_all->get_element(  ).
    *    get single attribute
         lo_el_cn_all->set_attribute(
           EXPORTING
             name  =  `INVISIBLE`
             value = '02' ).
    set attribute INVISBLE under context node cn_All to visible
    5 press control + f7 , use the radio button read context node /attribute
    for visible / invisble , instead of setting attribute to '01' and '02' , u can do it dis way
    wd_context->set_attribute( name = '<attribute name>' value = if_wdl_core=>visibility_visible )." to make it visible.
    wd_context->set_attribute( name = '<attribute name>' value = if_wdl_core=>visibility_none ). "to make it invisible
    this way u wud be able to achieve ur desired functionality
    regards,
    amit

  • Realtek network card seems to be disappeared. how can i make it visible again for the OS?

    i can't access my LAN card. somehow it is disappeared. how can i make it visible again for the OS? my OS is windows 7. thanks very much for your help

    right click on the button bar, then select "customize toolbar", drag any button you like into the toolbar and you're done!
    Diego

  • Start procejt with mc._invisible then make it visible by button, impossible? :

    Hello, like topic reads.
    Iv googling and trying to make my movieclip invisible from start and then make it visible as you hover over a button. It seems impossible. You make it invisible and when making it visible again it just flickers and dissappears. 
    Simply putting mc._visible = "false" in the code
    and then putting this on the button:
    on (rollOver) {
    mc._visible = "true" }
    WONT WORK.
    So if this is impossible, please just tell me and I will simply just skip the idea of having speech bubbles entering on rollover.  : )
    and btw, sorry if I come off as arrogant, ignorant and stupid.
    Im just so frustrated at the moment, I have spent 3 hours on something that initially I just wanted to add as a little nice detail.

    that should be:
    mc._visible=false;  // no quotes
    on(rollOver){
    mc._visible=true;  // no quotes
    // or, even better:
    yourbutton.onRollOver=function(){
    mc._visible=true;

  • Can someone tell me where in numbers 3.0 the formula bar is, or how I can make it visible?

    Hi,
    I've updated to the new numbers (3.0) and acutally it looks not back. But there is one point that really annoys me. I cannot find the formula bar and also I could not find in the menu where I can make it visible.
    Any hints from the community?
    Thanks

    DeSignature wrote:
    Every cell is a formula-editor now, that - once opened -  can be moved or resized.
    Needs a bit of getting-used-to.
    It only looks that way because the movable formula editor window starts out covering the cell. You can move it out of the way and it won't look like the cell any more.
    Jerry

  • Hello, I need to download the videos made with Ipad on a USB stick. How do I make them visible then with a Windows PC? I need to transform. Mov in that format? How to make? thanks

    hello, I need to download the videos made with Ipad on a USB stick. How do I make them visible then with a Windows PC? I need to transform. Mov in that format? How to make? thanks

    The camera connection kit can only be used to import photo/video files from a camera, SD card or USB flash drive. You can't import other types of files. You can't export any type of files using the camera connection kit.
    How to Transfer Photos from an iPad to a Computer
    http://www.wikihow.com/Transfer-Photos-from-an-iPad-to-a-Computer
    Importing Personal Photos and videos from your iOS device to your computer.
    http://support.apple.com/kb/HT4083
     Cheers, Tom

  • Invisible text in design view, how do I make it visible?

    I cant figure out why the text in Dreamweaver is invisible,
    though I can highlight it still, and see it fine in code view. I
    cant make it visible in design view. I dont see css attached to the
    text itself, only to the block, and other site elements, but
    something in css is causing the text to be hidden and I dont know
    how to make it visible. Anybody know what I should be editing or
    looking to edit?
    Thanks ahead of time.

    It sounds like a containing element may have display:none,
    and that is
    altered by JavaScript in the browser. DW Design View does not
    run
    JavaScript, so you won't see elements like that in Design
    View.
    If this is the case, and you are running CS3 (I think?) or
    later, go to
    Preferences > Invisible Elements and make sure
    display:none elements are
    turned on. This will show an icon in Design View that you
    can
    right-click and use Element View > Full (shortcut is to
    double-click) on
    to temporarily see that element. Use Element View > Hidden
    (or F5) to
    revert to the default view.
    You can also override display:none in a Design-time Style
    Sheet if you
    want to always see that/those elements.
    HTH,
    Randy
    > no, the text color is different and is definded in css
    file...and the browser
    > displays the text as defined, its the dreamweaver that
    makes it totally
    > invisible. I tried changing all "hidden" elements in css
    file to "visible" but
    > that didnt do it.

  • Making a field as not selectable(Readable) in dropdown box in HTML

    Hi All,
    I have one requirement like make a field as no selectable(readable) in dropdown box(combo) in HTML, Could you please any one of you help me out in this regard.
    If Drop down box contains values like blue,red,white..
    I want to make blue as not selectable from drown down list but it should be displayed in the drop down box.
    Thanks in advance.
    Thanks.
    Suresh Eluri.

    Add the disabled="true" tag in ur select box as shown below ....
    <select name="color" disabled="true">
    <option value="blue">Blue</option>
    <option value="red">Red</option>
    <option value="white">White</option>
    </select>
    Regards
    Rohit Kumar

  • How can I make new pages software spellcheck a selection like in appleworks?

    How can I make new pages software spellcheck a selection like in appleworks?
    I just installed pages a new download from apple store.
    1. I cannot find any way to activate a spellcheck for a selection in a document.
    2. I want to elemenate a red line under a word it doesn't like the spelling of.

  • How do I make them visible?

    I have an external hard drive that is split into one PC section and one Mac section. I have a new MacBookPro and now I want to copy some files from the PC section to the Mac section but can not see any files in the PC section to copy. How do I make them visible?
    Confused.

    Open Terminal in the Utilities folder. Enter at the prompt:
    chflags nohidden
    After the word "hidden" put a space and type in the path to and name of the file. For example, if they are on the Desktop: chflags nohidden ~/Desktop/name_of_file. Include the file's extension. Press RETURN. If all the files have the same extensions, then use chflags nohidden ~/Desktop/*.jpg or *.jpeg.

Maybe you are looking for

  • Urgent help needed for hysterical female!

    I need urgent help in editing a pic that has been emailed to me, I do not know which Adobe programme to upload it too.  Currently use Picasso - usually brilliant, but now gets jammed with a pop up box asking me to either accept or deny picnik.  When

  • Skype web cam

    I want a web cam to use on Skype, does it have to be the isight or is there a cheaper cam that would work?

  • Weird prob with sub query

    Hello All, I am having trouble with the code. I am using a subquery in the select statment and the same in the where clause(2nd sq in the select which populates on_hand column). I have highlighted the sub query as shown below. The code runs fine when

  • Oracle Arrays support in WLS7.0

    Getting a ClassCast Exception when using Oracle.jdbc.ArrayDescriptor.createDescritor("array",conn)

  • Availability group Automatic failover

    Hi setup a simple 2 node AG, sync. (SQL 2014 enterprise on windows 2012R2 standard) if I set it as manual failover everything works as expected. however when I switch to automatic failover and stop SQL service on the primary node the AG resource in c