Error bindind data i in radgrid

Posted by Jopito under ASP.NET on 11/12/2013 | Points: 10 | Views : 1299 | Status : [Member] | Replies : 2
Hellow great people,am bindind data from a radgrid using LINQ and this is the error i get

"Property accessor 'Title' on object 'Xpay.MerchantRegistration' threw the following exception:'Object reference not set to an instance of an object.'"

I have used a breakpoint and it shows the list of returned fields but now it cannot intergrate that to the grid,

Here is my code on page load
"List<MerchantRegistration> registrations = db.MerchantRegistrations.ToList();

RadGrid1. DataSource = registrations;

RadGrid1. DataBind();"

Can you guide me how to solve this please.Thank you

Mark as answer if satisfied


Responses

Posted by: Bandi on: 11/12/2013 [Member] [MVP] Platinum | Points: 25

Up
0
Down
Refer
http://stackoverflow.com/questions/18217359/property-accessor-title-on-object-x-threw-the-following-exceptionobject-refe

http://forums.asp.net/t/1930387.aspx?Property+accessor+Title+on+object+PIMS+Cost+threw+the+following+exception+Object+reference+not+set+to+an+instance+of+an+object+

Sample radGrid binding
http://demos.telerik.com/aspnet-ajax/grid/examples/programming/draganddrop/defaultcs.aspx
http://demos.telerik.com/aspnet-ajax/grid/examples/data-editing/manual-crud-operations/defaultcs.aspx

Mark This Response as Answer
--
Chandu
http://www.dotnetfunda.com/images/dnfmvp.gif

Jopito, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Bandi on: 11/21/2013 [Member] [MVP] Platinum | Points: 25

Up
0
Down
Have you solved the above issue?
Share the work around which you had so that it will help others too

Mark This Response as Answer
--
Chandu
http://www.dotnetfunda.com/images/dnfmvp.gif

Jopito, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response