Hi Brian,
I performed a test based on your code and did reproduce the problem.
When we bind a control to a property of data source, the value of the bound
property in the data source could be null, e.g. in your practice, the value
of the SiteLine.Site.CropAcres could be null and there will be no
exception.
However, if the SiteLine.Site property of an instance in the data source is
null, data binding couldn't find the Site property of the SiteLine property
of the instance, so exception occurs. This behavior is by design.
A workaround to this problem is to ensure that SiteLine.Site propery is not
null.
Hope this helps.
If you have any questions, please feel free to let us know.
BTW, I will be on a long vacation from the next Monday to Friday. During my
leave, my team mates will follow up with you and it may not in time. Sorry
for the inconvenience it may bring to you!
Sincerely,
Linda Liu
Microsoft Online Community Support
==================================================
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscripti...ult.aspx#notif
ications.
Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/subscripti...t/default.aspx.
==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.