Click here to Skip to main content
15,886,067 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
We are facing a problem like when we type the website URL and sign in it is working,but when we search the website URL from google and signing in it is saying Object reference not set to an instance of an object.Any views on this issue is much appreciated
Posted

1 solution

You're going to have to debug your code.

Somewhere, the line that is throwing the exception, your code is making an assumption that something returned an object when it returned null instead. The biggest noob mistake is to call something like FindControl("controlName") and then they assumed that the control was found, when it wasn't.
 
Share this answer
 
Comments
chandra sekhar 7-May-14 0:51am    
But when I get the URL from google how can I debug the code??As it just returns the URL and when I click on sign in I am getting the error.
Dave Kreskowiak 7-May-14 0:59am    
Attach the debugger to the web server process BEFORE you do the Google thing?
chandra sekhar 7-May-14 1:35am    
Is there any other way that we can find the solution??
Dave Kreskowiak 7-May-14 9:03am    
That's the best way to do it, but you can also go through some of the stuff you find here: http://weblogs.asp.net/scottgu/archive/2006/04/11/Don_1920_t-run-production-ASP.NET-Applications-with-debug_3D001D20_true_1D20_-enabled.aspx

You'll get better hints if you deploy debug versions of your code to the server and set debug compilation to true.

That's about the best you're going to get without direct debugging.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900