Results 1 to 6 of 6

Thread: Button breaks jscript?

  1. #1

    Thread Starter
    PowerPoster
    Join Date
    Aug 2003
    Location
    Edinburgh, UK
    Posts
    2,773

    Button breaks jscript?

    Hi

    in ASP.NET I have a javascript menu system (inserted in html code). This works fine. The menu shows and everything works fine. Cool.

    The thing is, when a user presses an ASP.NET button control, it somehow does not display the menu system anymore! It's just blank. The rest of the page loads fine and does its job, such as showing the other ASP.NET controls, databinding or whatever

    I am wondering why this is and how to resolve it if possible?

    MVP 2007-2010 any chance of a regain?
    Professional Software Developer and Infrastructure Engineer.

  2. #2
    Fanatic Member drpcken's Avatar
    Join Date
    Apr 2004
    Location
    devenv
    Posts
    591

    Re: Button breaks jscript?

    Strange. Can you show us the code for you button click handler?

    In the unlikely event that I answer your question correctly, please Rate my post

    Using Visual Studio 2005 Professional

  3. #3
    Super Moderator RobDog888's Avatar
    Join Date
    Apr 2001
    Location
    LA, Calif. Raiders #1 AKA:Gangsta Yoda™
    Posts
    60,713

    Re: Button breaks jscript?

    Do you get the JS exclamation error icon in your status bar of your browser?
    VB/Office Guru™ (AKA: Gangsta Yoda®)
    I dont answer coding questions via PM. Please post a thread in the appropriate forum.

    Microsoft MVP 2006-2011
    Office Development FAQ (C#, VB.NET, VB 6, VBA)
    Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
    If a post has helped you then Please Rate it!
    Reps & Rating PostsVS.NET on Vista Multiple .NET Framework Versions Office Primary Interop AssembliesVB/Office Guru™ Word SpellChecker™.NETVB/Office Guru™ Word SpellChecker™ VB6VB.NET Attributes Ex.Outlook Global Address ListAPI Viewer utility.NET API Viewer Utility
    System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6

  4. #4

    Thread Starter
    PowerPoster
    Join Date
    Aug 2003
    Location
    Edinburgh, UK
    Posts
    2,773

    Re: Button breaks jscript?

    i dont have any javascript errors at all when this happens

    the code can be even simple like as follows:

    Code:
    this.lblSomeLabel.Text = "boo"
    on some pages its fine, on other it isnt and have no idea why.

    on the pages that it does happen - this would be things like validating a simple form, if there is an incorrect entry, i return false....

    or even when I am databinding on some forms, it will cause the menu system not to appear but rather make it not there anymore unless i refresh the page

    MVP 2007-2010 any chance of a regain?
    Professional Software Developer and Infrastructure Engineer.

  5. #5
    Super Moderator RobDog888's Avatar
    Join Date
    Apr 2001
    Location
    LA, Calif. Raiders #1 AKA:Gangsta Yoda™
    Posts
    60,713

    Re: Button breaks jscript?

    Could it be something with the menu code then as simple safe code like what you posted wouldnt break anything.
    VB/Office Guru™ (AKA: Gangsta Yoda®)
    I dont answer coding questions via PM. Please post a thread in the appropriate forum.

    Microsoft MVP 2006-2011
    Office Development FAQ (C#, VB.NET, VB 6, VBA)
    Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
    If a post has helped you then Please Rate it!
    Reps & Rating PostsVS.NET on Vista Multiple .NET Framework Versions Office Primary Interop AssembliesVB/Office Guru™ Word SpellChecker™.NETVB/Office Guru™ Word SpellChecker™ VB6VB.NET Attributes Ex.Outlook Global Address ListAPI Viewer utility.NET API Viewer Utility
    System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6

  6. #6

    Thread Starter
    PowerPoster
    Join Date
    Aug 2003
    Location
    Edinburgh, UK
    Posts
    2,773

    Re: Button breaks jscript?

    yeh i totally understand. i doubt very much it could be the menu system as it works fine on most of the pages and not others.

    the menu system was made with a 3rd party program visually driven, i then just attached that js to the html code....

    right now, specifics:

    i have a form validator

    during validation of fields, if there is a field not of satisfactory value it returns false to the caller.... when this happens, no more menu!

    wierd!

    MVP 2007-2010 any chance of a regain?
    Professional Software Developer and Infrastructure Engineer.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width