Validation client javascript error

Discussion in 'ASP .Net' started by Gary Varga, Aug 27, 2003.

  1. Gary Varga

    Gary Varga Guest

    In the file WebUIValidation.js, when a postback that
    doesn't fail the validation has a javascript error saying
    summary is undefined in the ValidationSummaryOnSubmit
    function. Page_ValidationSummaries has a length of 1 but
    there are no array entries.

    This is the line that fails:

    summary.style.display = "none";

    TIA,
    Gary Varga
    Gary Varga, Aug 27, 2003
    #1
    1. Advertising

  2. Hi Gary,

    In order to help you, I need to recreate this problem on my own machine.
    What are the steps for setting up a page that will generate this error?

    Thank you, Mike Moore
    Microsoft, ASP.NET

    This posting is provided "AS IS", with no warranties, and confers no rights.


    --------------------
    > Content-Class: urn:content-classes:message
    > From: "Gary Varga" <>
    > Sender: "Gary Varga" <>
    > Subject: Validation client javascript error
    > Date: Wed, 27 Aug 2003 06:30:04 -0700
    > Lines: 12
    > Message-ID: <0d7001c36c9f$52f69f00$>
    > MIME-Version: 1.0
    > Content-Type: text/plain;
    > charset="iso-8859-1"
    > Content-Transfer-Encoding: 7bit
    > X-Newsreader: Microsoft CDO for Windows 2000
    > X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4910.0300
    > Thread-Index: AcNsn1L2OZnmTDrgR4SJMhBem5YJYA==
    > Newsgroups: microsoft.public.dotnet.framework.aspnet
    > Path: cpmsftngxa06.phx.gbl
    > Xref: cpmsftngxa06.phx.gbl microsoft.public.dotnet.framework.aspnet:171846
    > NNTP-Posting-Host: TK2MSFTNGXA11 10.40.1.163
    > X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet
    >
    > In the file WebUIValidation.js, when a postback that
    > doesn't fail the validation has a javascript error saying
    > summary is undefined in the ValidationSummaryOnSubmit
    > function. Page_ValidationSummaries has a length of 1 but
    > there are no array entries.
    >
    > This is the line that fails:
    >
    > summary.style.display = "none";
    >
    > TIA,
    > Gary Varga
    >
    Mike Moore [MSFT], Aug 27, 2003
    #2
    1. Advertising

  3. Gary Varga

    Gary Varga Guest

    Thanks for the reply, Mike.

    I have a control derived from ValidationSummary in a dll.
    I used this in a user control and included it in a page.
    This page is derived from a class which itself derives
    from System.Web.UI.Page.

    I can send you the dll and the updated WebUIValidation.js
    document - yes I have added to this in one place, I added
    a new display type - if you want.

    Regards,
    Gary

    >-----Original Message-----
    >Hi Gary,
    >
    >In order to help you, I need to recreate this problem on

    my own machine.
    >What are the steps for setting up a page that will

    generate this error?
    >
    >Thank you, Mike Moore
    >Microsoft, ASP.NET
    >
    >This posting is provided "AS IS", with no warranties,

    and confers no rights.
    >
    >
    >--------------------
    >> Content-Class: urn:content-classes:message
    >> From: "Gary Varga" <>
    >> Sender: "Gary Varga" <>
    >> Subject: Validation client javascript error
    >> Date: Wed, 27 Aug 2003 06:30:04 -0700
    >> Lines: 12
    >> Message-ID: <0d7001c36c9f$52f69f00$>
    >> MIME-Version: 1.0
    >> Content-Type: text/plain;
    >> charset="iso-8859-1"
    >> Content-Transfer-Encoding: 7bit
    >> X-Newsreader: Microsoft CDO for Windows 2000
    >> X-MimeOLE: Produced By Microsoft MimeOLE

    V5.50.4910.0300
    >> Thread-Index: AcNsn1L2OZnmTDrgR4SJMhBem5YJYA==
    >> Newsgroups: microsoft.public.dotnet.framework.aspnet
    >> Path: cpmsftngxa06.phx.gbl
    >> Xref: cpmsftngxa06.phx.gbl

    microsoft.public.dotnet.framework.aspnet:171846
    >> NNTP-Posting-Host: TK2MSFTNGXA11 10.40.1.163
    >> X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet
    >>
    >> In the file WebUIValidation.js, when a postback that
    >> doesn't fail the validation has a javascript error

    saying
    >> summary is undefined in the ValidationSummaryOnSubmit
    >> function. Page_ValidationSummaries has a length of 1

    but
    >> there are no array entries.
    >>
    >> This is the line that fails:
    >>
    >> summary.style.display = "none";
    >>
    >> TIA,
    >> Gary Varga
    >>

    >
    >.
    >
    Gary Varga, Aug 28, 2003
    #3
  4. Hi Gary,

    Here's my understanding of your problem statement.
    You have a custom validation control and you have customized your
    WebUIValidation.js file. After posting your page, the new page fails with a
    client script error related to a modified portion of WebUIValidation.js.
    This portion of your code expects an array with one entry, but the array
    has no entries.

    ---
    I recommend that you use view source to examine what the browser is
    receiving after the postback. Find the part that adds an entry to your
    Page_ValidationSummaries array. Somewhere within this you should see how it
    fails to add an entry to the array. This can then help you find what to
    change in your code so that the javascript code is correct.

    As part of this, I think you may want to create a new test page which is
    simplified. Remove as much complexity as possible while still reproducing
    the error.

    I realize this isn't an answer, but I hop it helps.

    Thank you, Mike Moore
    Microsoft, ASP.NET

    This posting is provided "AS IS", with no warranties, and confers no rights.


    --------------------
    > Content-Class: urn:content-classes:message
    > From: "Gary Varga" <>
    > Sender: "Gary Varga" <>
    > References: <0d7001c36c9f$52f69f00$>

    <>
    > Subject: RE: Validation client javascript error
    > Date: Thu, 28 Aug 2003 02:06:27 -0700
    > Lines: 70
    > Message-ID: <092301c36d43$a98dba20$>
    > MIME-Version: 1.0
    > Content-Type: text/plain;
    > charset="iso-8859-1"
    > Content-Transfer-Encoding: 7bit
    > X-Newsreader: Microsoft CDO for Windows 2000
    > X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4910.0300
    > Thread-Index: AcNtQ6mL2pSZcg75QsavRpyOSTxcvg==
    > Newsgroups: microsoft.public.dotnet.framework.aspnet
    > Path: cpmsftngxa06.phx.gbl
    > Xref: cpmsftngxa06.phx.gbl microsoft.public.dotnet.framework.aspnet:172224
    > NNTP-Posting-Host: TK2MSFTNGXA13 10.40.1.165
    > X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet
    >
    > Thanks for the reply, Mike.
    >
    > I have a control derived from ValidationSummary in a dll.
    > I used this in a user control and included it in a page.
    > This page is derived from a class which itself derives
    > from System.Web.UI.Page.
    >
    > I can send you the dll and the updated WebUIValidation.js
    > document - yes I have added to this in one place, I added
    > a new display type - if you want.
    >
    > Regards,
    > Gary
    >
    > >-----Original Message-----
    > >Hi Gary,
    > >
    > >In order to help you, I need to recreate this problem on

    > my own machine.
    > >What are the steps for setting up a page that will

    > generate this error?
    > >
    > >Thank you, Mike Moore
    > >Microsoft, ASP.NET
    > >
    > >This posting is provided "AS IS", with no warranties,

    > and confers no rights.
    > >
    > >
    > >--------------------
    > >> Content-Class: urn:content-classes:message
    > >> From: "Gary Varga" <>
    > >> Sender: "Gary Varga" <>
    > >> Subject: Validation client javascript error
    > >> Date: Wed, 27 Aug 2003 06:30:04 -0700
    > >> Lines: 12
    > >> Message-ID: <0d7001c36c9f$52f69f00$>
    > >> MIME-Version: 1.0
    > >> Content-Type: text/plain;
    > >> charset="iso-8859-1"
    > >> Content-Transfer-Encoding: 7bit
    > >> X-Newsreader: Microsoft CDO for Windows 2000
    > >> X-MimeOLE: Produced By Microsoft MimeOLE

    > V5.50.4910.0300
    > >> Thread-Index: AcNsn1L2OZnmTDrgR4SJMhBem5YJYA==
    > >> Newsgroups: microsoft.public.dotnet.framework.aspnet
    > >> Path: cpmsftngxa06.phx.gbl
    > >> Xref: cpmsftngxa06.phx.gbl

    > microsoft.public.dotnet.framework.aspnet:171846
    > >> NNTP-Posting-Host: TK2MSFTNGXA11 10.40.1.163
    > >> X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet
    > >>
    > >> In the file WebUIValidation.js, when a postback that
    > >> doesn't fail the validation has a javascript error

    > saying
    > >> summary is undefined in the ValidationSummaryOnSubmit
    > >> function. Page_ValidationSummaries has a length of 1

    > but
    > >> there are no array entries.
    > >>
    > >> This is the line that fails:
    > >>
    > >> summary.style.display = "none";
    > >>
    > >> TIA,
    > >> Gary Varga
    > >>

    > >
    > >.
    > >

    >
    Mike Moore [MSFT], Aug 29, 2003
    #4
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Libs
    Replies:
    0
    Views:
    1,492
  2. Matt
    Replies:
    14
    Views:
    4,096
    Chad Z. Hower aka Kudzu
    Jan 30, 2004
  3. =?Utf-8?B?dmlkeWE=?=
    Replies:
    1
    Views:
    750
    Kevin Spencer
    Jun 2, 2005
  4. Replies:
    1
    Views:
    3,783
    bruce barker
    Dec 12, 2008
  5. Sudip
    Replies:
    0
    Views:
    196
    Sudip
    Jul 1, 2005
Loading...

Share This Page