• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 552
  • Last Modified:

ASP.NET: Object reference not set to an instance of an object.

Hello,

We have developed a website and right now, it is running on the production environment.

It is running great on production environment but sometime it gives an error "Object reference not set to an instance of an object."

As of now, we have done concrete the problem. When user clicks on pop up window and close that window and Asychronous request goes to close that window. After that instantly click on "Update" button then this error comes.

It means that Page is not rendered properly.

Can anyone give assistance on it i.e. how to resolve it?

It is an urgent if some one assist me.

Best Regards,
Mohit Sharma
0
MohitPandit
Asked:
MohitPandit
1 Solution
 
BardobraveCommented:
This error means that your code is trying to use an object that is not instantiated on the moment your code try to call it.

Maybe the window you close is the one who instantiates the object, and when you close it, this object is sent to memory cleaner, so when another part of your code tries to reach it the exception is fired.

You should stretch the line where the error is raised and see what object is being called. Then you'll be able to see clearly what's happening.
0
 
SAMIR BHOGAYTAFreelancer and IT ConsultantCommented:
Hello,

May be your code is trying to use the object which is not instantiated into your code. OR may be the database is not properly connected at the time of pass the query for that page.
0
 
meispiscesCommented:
Post your code.. this would be helpful to see where the error is..

thanks!
0
What Kind of Coding Program is Right for You?

There are many ways to learn to code these days. From coding bootcamps like Flatiron School to online courses to totally free beginner resources. The best way to learn to code depends on many factors, but the most important one is you. See what course is best for you.

 
Dinesh SubramanianSenior Software EngineerCommented:
hi...,
can you please explain, what is the window you have used for pop-up.
is it a JavaScript pop-up or a child instance of the parent window.
0
 
MohitPanditAuthor Commented:
Hi dinudany,

We are using Telerik: RadwindowManager.

FYI only, we grab the issue. I tried to same "object reference" error from other development machine but we couldn't. So, we created new published code from that development machine and tried to replicate but error didn't come.

It means that there is problem with old development machine from where we created published code everytime.

Do you have any suggestion on it?

Regards,
MohitPandit
0
 
MohitPanditAuthor Commented:
Any Suggestion?
0
 
MohitPanditAuthor Commented:
Hello,

I found this file "BrowserFile.browser" in App_Browser folder in published code. After remove it, it doesn't through any "Object Reference" error

Regards,
Mohit
0
 
MohitPanditAuthor Commented:
I found myself. thanks
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

What Kind of Coding Program is Right for You?

There are many ways to learn to code these days. From coding bootcamps like Flatiron School to online courses to totally free beginner resources. The best way to learn to code depends on many factors, but the most important one is you. See what course is best for you.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now