Windows Phone 7: application development caveat with ViewModel entity class

The other day I played around with the newest release of the Windows Phone 7 SDK (7.1 Beta 2) and started by using the base application template. I created a new class that serves as the entity definition for the view model. The data is bound to a list box. Nothing spectacular.

In design time (Visual Studio) my static sample data that I created showed up just fine. During application start I created some “real” data and bound it to the list box. As a result, the list box is empty and does not show any data at all … no exceptions or other runtime errors. After a bit of testing I found out that the problem is with the entity class definition. The class was specified to be private instead of public. This little keyword led to an empty list box.

Leave a comment

Your email address will not be published. Required fields are marked *