hello
when I run my application, I have this error message
"la référence d'objet n'est pas définie à une instance d'un objet"
I would like to avoid displaying this error message.
Best regard
hello
when I run my application, I have this error message
"la référence d'objet n'est pas définie à une instance d'un objet"
I would like to avoid displaying this error message.
Best regard
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Niradhip ChakrabortyPosted May 5, 2009, 9:46 AM
say you have a form called as "error". In this form You can have some custom message.
Now say you are geting error in sudmit event handler. It will go to catch block and close the form and open the error form which you have created for custom message
private void btnSave_Click(object sender, System.EventArgs e)
{
try
{
//put all your submit event handler code here
}
catch
{
// code to close this form and open the error form here
}
finally
{
}
}
Posted May 5, 2009, 9:26 AM
How to do it ?
Niradhip ChakrabortyPosted May 5, 2009, 9:07 AM
Posted May 5, 2009, 8:21 AM
hello;
I know this solution but, I would like hide this message !
have you any solution ?
have a nice week end
Mahesh ChandPosted May 4, 2009, 3:24 PM
As message says, you first must create an object using "new" keyword. Avoiding error message is not going to help.