10
Answers

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

Ask a question
AL MUBARAK

AL MUBARAK

12y
5.6k
1
Hi,


  i had bug in getting dataset value from databse. but the corresponsing value is in null. so it is returns Null value in dataset. it return the expection and sows the error of like below,

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

Here is my code :

DataSet ds = service.GetDataSet("sp_smsinbox", "@action$#!@$@substr", "count$#!@$" + substr);  

 
  The substr get the values from application and fetch into dataset. but the dataset had null value, then it redirectd the error.

page.

Can anyone please help me to achieve this.

Any help will be greatly appreciated.

Thanks
Mubarak

Answers (10)