JavaScript to remove the subform

Hello!

Can someone please tell me what am I doing wrong and why the subform is not removed when I push the button 'Remove the position' ?

I use the command _Subformname.removeInstance (1);

Is that correct. Help, please!

Set the property to "min" on each form as '0' (zero) before making a removeInstance and set the argument removeInstance on '0' (zero). The seal contains the update ' click on ' event as for Subform1 scripts, below.

Form1. Subform1.Subform1.Button1::click - (JavaScript, client)

Form1. Subform1._Subform1.occur.min = '0 '.

Form1. Subform1._Subform1.removeInstance (0);

Steve

Tags: Adobe LiveCycle

Similar Questions

  • JavaScript to remove the signatures on certified form

    I have a form with 3 additional signature lines. Since resetData does not work on certified forms I need a javascript command to rest three signatures. Any help would be great.

    It is not possible via the script. The person who signed the form, only he can remove his signature. This is done to maintain security PDF.

  • JavaScript to remove the contents of the fields based on the checkbox disabled

    I'm writing a java script to delete the contents of the fields when a checkbox's checked to disabled.  I have a java script to fill in the field when the checkbox is enabled (which works perfectly).  But in the case where the user accidentally checks the field and wants to uncheck the box I would like the content of field that were initially filled from the first java script to be removed/disabled.

    Here is my code:

    Mouse Up Script for the checkbox (function() {}

    Do something if this check box is not selected.
    if(Event.Target.Value==="on") return;

    Copy the values from text previously filled in those other fields.

    getField("AP_Unit").value = Null;
    getField("AP_StreetAddress").value = Null;
    getField("AP_City").value = Null;
    getField("AP_Province").value = Null;
    getField("AP_ZIP").value = Null;
    getField("AP_Country").value = Null;

    })();

    Sorry it works... that make three equal signs "=" means?

    Here is my code

    If {(event.target.value==="Off)"}
    getField("AP_Unit").value =("");
    getField("AP_StreetAddress").value =("");
    getField("AP_City").value =("");
    getField("AP_Province").value =("");
    getField("AP_ZIP").value =("");
    getField("AP_Country").value =("");

    } else {}

    getField("AP_Unit").value = getField("HO_Unit").valueAsString;
    getField("AP_StreetAddress").value = getField("HO_StreetAddress").valueAsString;
    getField("AP_City").value = getField("HO_City").valueAsString;
    getField("AP_Province").value = getField("HO_Province").valueAsString;
    getField("AP_ZIP").value = getField("HO_ZIP").valueAsString;
    getField("AP_Country").value = getField("HO_Country").valueAsString;
    }

  • Remove the JavaScript

    Hello

    I have to make sure that there is no JavaScript code in my PDF documents. Some documents come from the Internet, while others are created using the Adobe PDF of Acrobat X printer. I'll have to deal with multiple documents per week.

    I read in this post Re: remove script on a correction before the flight. However, I couldn't he find in Acrobat X Pro. What is the best way to remove the JavaScript code possible?

    Thank you very much!

    In the upper search box, enter "Javascript" and you should include a list like the following (which is Acrobat 9):

    The one you want is the last of them.

  • Auto dc Acrobat reader starts Javascripts Javascript directory. How can I stop it without removing the javascripts in the directory?

    We have a third party application that requires three manuscripts of java to exist in Javascript directory in c:\Program DC\Reader of Adobe Acrobat Reader.

    Scripts are provided by the seller and at no time never change us them. The problem now is that since the update to Acrobat Reader DC java scripts run automatically whenever Acrobat Reader opens. It doesn't matter if it's a PDF file which opens the player or if you open the drive by itself before opening a PDF file. It is used for java scripts run only when the third-party application called what he calls a sympdf file. Once the pdf file has been loaded scripts would go and a toolbar will appear with several options on this subject. This toolbar now appears each time we open Acrobat reader. How can I keep Acrobat Reader automatically executing the script without removing the script from the Javascripts directory?

    Thank you

    Javier

    All scripts in this case are automatically loaded the application whenever you open.

    From what you describe, it looks like a bug in the scripts themselves. You must report it to the company, you've got to go.

    To disable them, you can delete or rename or disable JS entirely under Edit - Preferences - JavaScript (but which would have an impact on other things and is not recommended).

  • Help! 'remove the rendered JavaScript blocking' and 'leverage browser caching.

    My site Adobe Muse, www.realtorindfw.com, (desktop version) loading fine until yesterday. Now it loads very slowly, I tried to reduce the size of the image, thinking that maybe the problem (even if it used to load incredibly fast even when the images were 4 x greater, so I never thought that). When that didn't fix the problem I typed my website in Google PageSpeed and found that the main problem is that I need to 'remove the rendered JavaScript blocking' and "leverage browser caching."

    It seems that the main problem is that the file, http://webfonts.creativecloud.com/...eue:n4:all; open-without - condensed:n3:all.js, is apparently rendered blocking JavaScript which is causing all the rest to be delayed, because images can not load until this line is resolved and that can take up to a minute. Reading online, it seems that if I could move this line of code to the bottom, then it don't take everything, because no assets would be behind it. I obviously know nothing about good coding (that's why I use Muse). How can I go about solving this problem of render-blocking JavaScript?

    In addition, the issue of "leverage implementing caching of the browser" is that some images have an expiration are associated. I do not think this has nothing to do with me and is rather a kind of problem of Muse. Is there a way can I fix?

    My page was loading fine, until I downloaded randomly once again, and all these problems started. Please type my site in PageSpeed and address the problems of the desktop version and see if you can understand how this can be resolved. This is my professional site, so yes, I'm trying to get it fixed as soon as possible. I also discussed with support chat and they said that the best way to get it resolved would be to post it here. Thank you.

    debp83130756 if your page is slow to load, start a new thread here on the forum, ask for advice on improving the performance of page loading, and include the URL of the page. (A new thread will attract more attention than to post a reply in a thread that has been dormant for more than a year.)

    PageSpeed side has surprisingly little to page load performance as experienced by a visitor to the site and is not related to SEO or your Google page ranking.

    Him "generally render JavaScript blocking" on a Muse page is code that starts to load Web fonts. If it was moved later then the content of your page may appear a fraction earlier, but it appears in the wrong font, and then jump around to settle once the police you wanted has been loaded. Most of the people prefer to avoid content in the police hurt, insofar as that it can be avoided.

  • Remove the instance and hiding the subform

    Hello world

    I have a problem with the instance Manager.

    I have a subform repeated containing a button Delete. The delete action works great until I have remove the last instance I want action, not only to remove the last instance, but also to hide the entire subform.

    I use this script on the click event:

    _Person1.removeInstance (this.parent.parent.index);

    I tried to put this on the MouseUp: (found here: http://forums.adobe.com/message/4137110#4137110)

    if (this.parent.parent.instanceIndex == this.parent.parent.instanceManager.count 1) { }

    form1. Personer.Presence = 'hidden';

    xfa.host.messageBox ("what it was");

    }

    else {

    form1. Personer.Presence = 'present';

    xfa.host.messageBox ("" Hello, more cases "");

    }

    If I have multiple instances and delete number one or two, everything works fine. But if I start by removing the last instance that all previous instances are also deleted and the subform "Guests" is hidden. I wanted to just remove one instance at a time.

    Hope there's help out there

    I think what happens is that when you check the Instance Manager for the count, there is nothing to count because there are no bodies. That and try to do it from the object that is removed, there is probably something there too.

    To access the Manager of the Instance of non-existing objects, you must use the shortcut of underscore.

    Then try this on the layout event: loan of the guests subform:

    If (_Person1.count == 0) {}

    This.Presence = 'hidden ';

    }

  • Hide all instances of the subform with a single line of javascript

    Is it possible to hide all instances of a subform with a single line of javascript?  I'm looking for something like this:

    repeatingSubform [*] .its presence = "hidden";

    but which caused the designer...

    Or do I have to loop through all instances of the subform and disable individually each of them?

    Thank you

    Elaine

    You must disable them individually

    Paul

  • Writing javascript code to a box that when activated, it removes the read-only attribute in another area and allows a number against the default calculation that occur.

    I have an order entry form that calculates a sum of $ calculate markup by a formula in the section rating field simplified in the field on the tab properties.  The field of markup is set to read-only.  I also have a configuration like a checkbox.  If the user selects the check box, I need this field of markup to become editable (remove the read-only attribute) to allow a number to be entered in the field.  I guess I'd also need programmatically delete the calculation in the simplified field notation when the box has been activated.  I think I need a custom java script to trigger on mouse enter?  I could also use some help setting java script.  Someone has it all done something similar?

    Thanks in advance.

    You can no longer use the method of the "simple field notation" If you change the field in certain situations. The following script assumes that you just want to add two fields and use 25% of this amount as your markup, unless the box named "CheckBox" is checked, then the field will become editable and you can enter what you want:

    // get the state of the "CheckBox" - modify the field name to match your form
    var cb = this.getField("CheckBox");
    
    if (cb.value == "Off") {
        // Checkbox is unchecked, so perform the calculation and make sure the field is read-only
        event.target.readonly = true;
         // simple calculation - you need to modify this
        var result = (Number(this.getField("Field1").value) + Number(this.getField("Field2").value)) * 0.25;
        event.value = result;
    }
    else {
        // Checkbox is checked, so do not modify the value, set the field to read/write and let the user enter anything they want.
        event.target.readonly = false;
    }
    
  • How to remove the value of the XML attribute in the Indesign file with javascript

    Hi all

    How to remove the value of the XML attribute in the Indesign file.

    1.jpg

    What error is this?

    in any case try this as well (one another),

    var myDoc = app.activeDocument;
    attrDelete(myDoc);
    function attrDelete(elm)
    {
        for (var i = 0; i < elm.xmlElements.length; i++)
        {
            try{
                for(j=0; j
    

    Vandy

  • Remove the line with alert button

    Hello

    I have a table which can add and delete rows dynamically. An alert must be added to the button delete what I've done.  The works warning, but when you select OK on the alert line is not deleted.

    It would be the right way to accomplish this?

    I'm not a programmer and now wondering if my edit code is wrong or there is an alternative solution.

    Thank you

    Capture.PNG

    This is the code I have for the button Delete.

    Form1. FSE_1.Pre_EX. Buttons. Remove::click - (JavaScript, both)

    CMSG var = "continues with the action underway will remove all entries in cell in this row.

    CMSG += ' \n\nDo you want to continue?

    var nRtn = app.alert (GSMC, 1, 1, 'Question Alert Box');

    if(nRtn == 4)

    {If (Table1._Item.count > 1)

    Table1._item.removeInstance (Table1._Item.count - 1);

    Console.println ("the answer is Yes");

    }

    Another yew (nRtn is 3)

    {/ / No answer}

    Console.println ("the answer is no");

    }

    on the other

    {//Unknown response

    Console.println ("the response was something other than yes/no:"+ nRtn ");

    }

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

    This is the code I have for the button Delete before adding the alert that worked.

    Form1. FSE_1.Day_1.buttons.Remove::click - (JavaScript, both)

    If (Table1._Item.count > 1)

    Table1._item.removeInstance (Table1._Item.count - 1);

    The way I understand how it works at the moment, is that you remove the last line of the table... If you want to delete the line where is the button Delete, you should be removing the instance itself with its index...

    rather than use the following line

    Table1._item.removeInstance (Table1._Item.count - 1);

    You should have something like this

    'this' being button and tell me that you have a subform to remove and add the button

    Table1._item.removeInstance (this.parent.parent.index); the first parent is the subform and the second parent is the line

    I hope this helps!

  • Cannot reset the border of the subform?

    I'm changing the JavaScript ColorFieldsValidation to manage a situation where I want the subform set containing all fields failed to be highlighted. Highlighting works well. However, even when validation is successful, highlighting persists. I think I narrowed down it to line 32, which seems only to remove the lower border. I know that this code was written to remove the borders of fields, but why it works not for subforms?

    function InitializeColorFields() {
        // Disable Acrobat's field highlighting. The Color
        // Failed Fields action takes care of highlighting fields.
        if (xfa.host.name == "Acrobat") {
            app.runtimeHighlight = false;
        }
    }
    function DoColorFields(oInvalidNode) {
        // If this form is running on a client other than Acrobat
        // (like on the server) then don't run this script
        if (xfa.host.name != "Acrobat") {
            return;
        }
        var sClassName = oInvalidNode.className;
       
        // Only contests, so nodes that are <field>s and
        // have name "Selected"
        // Ignore everything else
        if ((sClassName != "field") &&
            (oInvalidNode.name != "Selected")) {
            return;
        }
       
        //get closest Contest
        var nearestContest = oInvalidNode.resolveNode("Contest")
        if (oInvalidNode.errorText == "") {       
            // Validation Succeeded
            // Revert the appearance to its original state           
            console.println("we good for " + oInvalidNode.name);
            var oBorder = nearestContest.border;
            //does not work!       
            oBorder.parent.nodes.remove(oBorder);           
                   
        }
        else {       
            // Validation Failed
            // Show the invalid appearance
            var oFailedBorder = nearestContest.border;
            // Border color
            // Show a solid border with square corners
            var sBorderColor;
                sBorderColor = "51, 102, 255";   
            if (sBorderColor != "none") {
           
                oFailedBorder.presence = "visible";
               
                for (var i = 0; i < 4; i++) {
                    var oEdge = oFailedBorder.getElement("edge", i);
                   
                    oEdge.presence = "visible";
                    oEdge.color.value = sBorderColor;
                    oEdge.thickness = "2pt";
                    oEdge.stroke = "solid";
                   
                    var oCorner = oFailedBorder.getElement("corner", i);
           
                    oCorner.presence = "visible";
                    oCorner.color.value = sBorderColor;
                    oCorner.thickness = "2pt";
                    oCorner.stroke = "solid";
                    oCorner.join = "square";
                    oCorner.inverted = "0";
                    oCorner.radius = "0mm";
                }
            }
    
            // Background color
            // Show a solid fill color
            var sFillColor;       
            sFillColor = "153, 204, 255";
    
            if (sFillColor != "none") {
                // The presence of the border must be visible to show the fill.
                // Hide the edges when the invalid appearance doesn't include
                // changing the border color
                if (oFailedBorder.presence != "visible") {
                    oFailedBorder.presence = "visible";
                    oFailedBorder.edge.presence = "invisible";
                }
               
                // Replace the current fill type with a solid fill
                if (oFailedBorder.fill.oneOfChild.className != "solid") {
                    var oFailedFillType = oFailedBorder.fill.oneOfChild;
                    oFailedBorder.fill.nodes.remove(oFailedFillType);
                   
                    var oSolid = xfa.form.createNode("solid", "");           
                    oFailedBorder.fill.nodes.append(oSolid);
                }
                oFailedBorder.fill.color.value = sFillColor;
            }       
        }
    }
    
    

    An example that illustrates this problem is here: Acrobat.com shared - files

    I have "fixed" the problem by changing the line 32 to this:

    xfa.resolveNode(nearestContest.border.somExpression).presence = "invisible";
    

    It seems that, contrary to the edge of a field, border of a subform cannot be removed.

  • Add/Remove the same exact point from a drop down list

    Hello!

    I need power remove/hide and/add/view THE SAME POINT, or that it doesn't look like the same question, please see the example of what I m doing:

    When you open the document:

    01.png

    If you click 'Yes' to the first radio 4 value is added

    02.png

    If you click 'Yes' in the second radio, value 5 is added

    03.png

    If you click 'no' on the first radio, you remove the value 4 BECAUSE you remove the element #3

    04.png

    If you click on 'no' on the second radio, you delete nothing 4 BECAUSE you try to delete the point #4


    05.png

    And then you get this weird combination

    06.png

    This is the code on the first Radio

     form1.#subform[0].value_4::click - (JavaScript, client)

    if (this.rawValue == "1") {
         DropDownList1.addItem("value 4");
    }else {
        DropDownList1.deleteItem(3);
    }

    This is the code on the second radio

     form1.#subform[0].value_5::click - (JavaScript, client)

    if
    (this.rawValue == "1") {
           DropDownList1.addItem("value 5");
    }else {
           DropDownList1.deleteItem(4);
    }

    Anyone know how to remove a specific item of a dropdrown? or may not remove, hide only if this is possible... I tried to change specific values for Add/Remove always from the same point, but it did not work.

    Thank you!

    Ago, I find it odd that there is no native method xfa for the index of an item in the menu drop-down. Not documented at least (as I know).

    What you can do however, is create your own method!

    Here, in the initialize event of your highest subform you create a method that exends class object (which includes all XFA objects too), like native JavaScript:

    //@para String value of the item in the drop down
    //@return Boolean - true if item was deleted, false if not and null object if not found in the list
    
     Object.prototype.deleteItemValue=function(sVal){
     for (var a=0;a
    

    You can remove any item from your drop by modying your code:

    if (this.rawValue == "1") {
     DropDownList1.addItem("value 4");
    }
      else {
     DropDownList1.deleteItemValue("value 4");
    }
    

    Kyle

  • ValueChangeListner do not get fired when I entered the same value after you remove the first.

    Hello world

    Can anyone help on this.

    JDeveloper version 11.1.1.7

    I use '< af:inputText >' with valueCaangeListner.

    Here as soon as I entered a value, valueChangeListener get fired...

    Problem:

    When I remove the and I entered the same gain value in the text entry box, ValueChangeListner do not get fired.

    When I came again, a value different valueChangelistner get me fired.

    Kind regards

    Malenfant.

    What you say is logic and sense, you enter 500 then delete 00 then add 00 in inputText perspective there is no change in place, therefore, the converter does not occur because there is no changes occur.

    To do something like that you can do a work around using javascript. You can follow these steps:

    1. Select af:inputText and bind it to the backbean

    
    

    2 - Add clientListener and serverListener inside inputText as:

    
        
        
        
    
    

    3 - Add handelEnterButton as javascript method:

    function handelEnterButton(event)
    {
      var code=event.getKeyCode();
      if (code==13)
      {
         var source = event.getSource();
         AdfCustomEvent.queue(source,"serverListenerOperations", {}, false);
      }
    }
    

    4. in the method of serverListener back bean refresh as inputText component:

      public void serverListener(ClientEvent clientEvent)
      {
        RequestContext.getCurrentInstance().addPartialTarget(getMyInputTextComponent());
      }
    

    5. now, try to change something in the inputText and then press enter

  • How to remove the comments in the example of Application Feedback?

    After you install the sample application to the comments tab, when I click on the line button Feedback, the only buttons are cancel and apply the changes.

    How can I remove a Feedback?

    Hello

    1009491 wrote:

    Please update your profile name with a meaningful name.

    After you install the sample application to the comments tab.
    When I click on the line button of feedback, the only buttons are cancel and apply the changes, how do I remove a Feedback?

    You add the delete button to remove the comments.

    (1) to unlock Application Feedback

    Go to request-> click on Manage-> Unlock

    (2) edit your comment Page (Page 26) comments

    Create a button with the following details (properties button available in the right pane of the page after creating the button)

    Under Identification

    Button name: REMOVE

    Label: delete

    Under behavior

    Action: Redirect URL

    URL: javascript:apex.confirm (htmldb_delete_message, 'DELETE');

    Action of the database: SQL DELETE Action

    Under Condition

    Type: Is not null

    Article: P26_ID

    3) go to the treatment Section. There is an icon for the treatment in the upper left corner.

    Check this screen shot to pass the processing section

    Change the line EBA_FEEDBACK_COMMENTS process

    under settings of-> supported operations

    Delete is checked

    Hope this helps you,

    Kind regards

    Jitendra

Maybe you are looking for

  • I can add a 2nd HDD on my Satellite A300 - 02c?

    Hi all I wonder if it is possible to add a 2nd HDD in my A300 - 02c?There is a HDD 2 slot, but no sata connector on the card (see the link to the image). http://www.NotebookReview.com/picture.asp?f=36752 I wonder if it is possible to add the connecto

  • Why iTunes 12 do not sync new music to my iPhone 6 s +?

    Last week, I downloaded a few new songs, and I realized later they do not sync to my iPhone at all. My phone is updated 9.2.1 and iTunes is the latest version. I already have the option 'Only downloaded music' unchecked my music application, and who

  • Camileo Pro HD - where to find additional functions

    Hello! I recently bought a Toshiba "* Camileo Pro HD * ' camcorder and now I'm wondering where I can find the mp3 player, the motion detector or the eBook functionality? I can't find them in the menu. The manual doesn't mention one of these functions

  • menu to come not when the sd card set

    Something has changed, use the menu to come when I put the sd card in the drive and put it in the front usb port. He asked if I wanted to copy, display, publish on the web site, etc... Now it comes automatically in card view. Can he come back for any

  • Windows XP is a huge 96 concert .no downloads or virus help

    XP genuine. No temp, no download file, no virus, right click on drive C, R, click the Windows folder, properties, results show a huge concert 96. HOW TO REDUCE THIS PLEASE