Solved

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

Posted on 2004-08-19
3
2,521 Views
Last Modified: 2012-06-27
Server Error in '/dotNetAlumni' 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:


Line 28:     Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Line 29:         'Put user code to initialize the page here
Line 30:         lblTitle.InnerHtml = Application("Institution") & " Alumni Portal"
Line 31:         lblInstitution.Text = Application("Institution")
Line 32:
 

Source File: c:\inetpub\wwwroot\dotNetAlumni\default.aspx.vb    Line: 30

Stack Trace:


[NullReferenceException: Object reference not set to an instance of an object.]
   dotNetAlumni._default.Page_Load(Object sender, EventArgs e) in c:\inetpub\wwwroot\dotNetAlumni\default.aspx.vb:30
   System.Web.UI.Control.OnLoad(EventArgs e)
   System.Web.UI.Control.LoadRecursive()
   System.Web.UI.Page.ProcessRequestMain()

 


--------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:1.1.4322.573; ASP.NET Version:1.1.4322.573
0
Comment
Question by:smetterd
  • 2
3 Comments
 
LVL 4

Accepted Solution

by:
Sandeepk1999 earned 500 total points
ID: 11846100
Can you post the source code?

Looks like lblTitle is a HTML object and not a server object.

0
 
LVL 2

Author Comment

by:smetterd
ID: 11846464
Added runat="server" on that control and voila. Thanks Sandeepk
0
 
LVL 2

Author Comment

by:smetterd
ID: 11846501
0

Featured Post

Free Tool: Postgres Monitoring System

A PHP and Perl based system to collect and display usage statistics from PostgreSQL databases.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Help with error in Query 2 31
Very Large data in MYSQL 7 73
Passing data between Forms 3 20
run a stored procedure from vb.net 1 27
This article explains how to create and use a custom WaterMark textbox class.  The custom WaterMark textbox class allows you to set the WaterMark Background Color and WaterMark text at design time.   IMAGE OF WATERMARKS STEPS Create VB …
A while ago, I was working on a Windows Forms application and I needed a special label control with reflection (glass) effect to show some titles in a stylish way. I've always enjoyed working with graphics, but it's never too clever to re-invent …
Email security requires an ever evolving service that stays up to date with counter-evolving threats. The Email Laundry perform Research and Development to ensure their email security service evolves faster than cyber criminals. We apply our Threat…
In an interesting question (https://www.experts-exchange.com/questions/29008360/) here at Experts Exchange, a member asked how to split a single image into multiple images. The primary usage for this is to place many photographs on a flatbed scanner…

840 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question