Exemple #1
0
        /// <summary>Resets this form.</summary>
        public void reset()
        {
            // Dispatch the reset event:
            FormEvent de = new FormEvent("reset");

            de.SetTrusted(true);
            // Hook up the form element:
            de.form = this;

            if (dispatchEvent(de))
            {
                // Get resettable elements:
                HTMLFormControlsCollection allReset = GetAllInputs(InputSearchMode.Submittable);

                foreach (Element e in allReset)
                {
                    HtmlElement he = (e as HtmlElement);

                    if (he != null)
                    {
                        he.OnFormReset();
                    }
                }
            }
        }