How to debug an asp.net 1.1 VB web application

Last post 06-14-2009 11:28 PM by Thomas Sun – MSFT. 3 replies.

Sort Posts:

  • How to debug an asp.net 1.1 VB web application

    06-03-2009, 4:56 PM
    • Member
      1 point Member
    • naumlitvin
    • Member since 10-07-2008, 8:21 PM
    • Posts 5
    I have an VB ASP.NET 1.1 code that works on my local machine and on development server.

    however when I run it on production server I get an error (see below).

    considering that the code works on two servers the only difference seems to be the database, but how can I zero in to the problem from what I see in the error message?

    this code is result of minor modification of working page. the textbox "Pilotcoater" had been changed to a drop-down box reading data from PilotCoater table. The table exists on the production server, the code seems not to use any stored procedures...

    Could someone help me to debug the error?

    I can send the code... any assistance will be appreciated

    ==============
    Server Error in '/' Application.
    --------------------------------------------------------------------------------

    Object reference not set to an instance of an object.
    Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

    Exception Details: System.NullReferenceException: Object reference not set to an instance of an object.

    Source Error:

    An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

    Stack Trace:

    [NullReferenceException: Object reference not set to an instance of an object.]
    Templeton.CopyofGridTestPilotCoaterSubmittalHeader.Page_Load(Object sender, EventArgs e)
    System.Web.UI.Control.OnLoad(EventArgs e) +67
    System.Web.UI.Control.LoadRecursive() +35
    System.Web.UI.Page.ProcessRequestMain() +739

    --------------------------------------------------------------------------------
    Version Information: Microsoft .NET Framework Version:1.1.4322.2407; ASP.NET Version:1.1.4322.2407
  • Re: How to debug an asp.net 1.1 VB web application

    06-09-2009, 5:57 AM
    Answer

    Hi,

    From the stack trace, the exception is thrown from CopyofGridTestPilotCoaterSubmittalHeader Page_Load event. Please check the object that is used in this Page_Load event.

    How did you modify your page? Please make sure it can be built succeeded in development machine and they use same database in development machine and production server.

    If this doesn't help you, please post the Page_Load event here and clarify in detail.

     

    I look forward to receiving your test results.

    Thomas Sun
    Microsoft Online Community Support

    Please remember to click “Mark as Answer” on the post that helps you, and to click “Unmark as Answer” if a marked post does not actually answer your question.
  • Re: How to debug an asp.net 1.1 VB web application

    06-12-2009, 8:50 AM
    • Member
      1 point Member
    • naumlitvin
    • Member since 10-07-2008, 8:21 PM
    • Posts 5
    Thanks for responding so quickly, it actually confused me a bit - I took notification of your response for a confirmation of the post itself and did not look at it until now - sorry.

    As far as I remember the problem was either that I did not copy the .dll from development to production or that our admin tinkered with security and/or database permissions. Now the code works fine.

    However there still are few items where I could use some guidance:

    1) How to bring a working project from web server to development machine for modifications?

    2) What should be my steps if I need to modify few pages and do not have project on my development computer? How do I incorporate changes in .aspx.vb for these few pages into single .dll assembly for the project?

    3) What are references to objects, where are they defined (setup) and how they work? The documentation has 100s times more info than I need, I did not find a short simple explanation yet... 4) Can I have different project names on development and on web server for the same code or they must be the same (how is "project name" related to namespaces?) I tried to create a project on my development machine with the same name as in production but VS2003 would not let me. It claims that "another project already exists in the folder '\'" and I do not see it anywhere... Then I created new solution and was able to create an empty project with same name as in production. Should I now simply copy all files and folders from production server down to my development machine overriding files created for that project (AssemblyInfo.vb, Global.asax, Styles.css, Web.config and WebForm1.aspx)? After I make changes and build it locally I should be able to upload changed .aspx files and .dll created during the build process? The changed .vb files are needed simply for integrity of the code but they are not used, .dll is used instead, right?

    5) Step-by-step guide for upgrading an ASP.NET 1.1 Project to ASP.NET 2.0 - I assume there should be some good "to the point" steps, can you point me to one or more please?

    6) Step-by-step guide for changing data sources from using built-in SQL to Stored Procedures (if it exists). If you do not know of one, maybe just say few words on what direction to go and I will do my best...

    Thanks a lot in advance
  • Re: How to debug an asp.net 1.1 VB web application

    06-14-2009, 11:28 PM
    Answer

    Hi,

    Thanks for your response.

    I will pick up some questions and then you can open new post to discuss them separately. This is better for other people who has the same question.

    For ASP.NET 1.1 project, to modofy it, we need to modify it in Visual Studio and build it, and then redeploy it on server.

    To upgrade an ASP.NET 1.1 Project to ASP.NET 2.0, please see http://msdn.microsoft.com/en-us/library/ms228097.aspx and http://webproject.scottgu.com/CSharp/Migration/Migration.aspx

     

    Thanks.

    Thomas Sun
    Microsoft Online Community Support

    Please remember to click “Mark as Answer” on the post that helps you, and to click “Unmark as Answer” if a marked post does not actually answer your question.
Page 1 of 1 (4 items)