Implementing a Base Silverlight UserControl
Last post 05-09-2008 9:02 AM by Puts. 0 replies.
Sort Posts:
05-09-2008 9:02 AM
Implementing a Base Silverlight UserControl

Hello, i have found some wierdness when trying to inherit a base silverlight user control much as i would reference a base page in asp.net.  When changing the base class of a page it properly reflects the base class in the mostly unseen .g partial class that is created.  When i do the same with a silverlight control it does not change the .g file.  I was able to manually go in and set the base class in the g file and it worked correctly.  When i choose Build it retains the base class.  If i choose Rebuild it resets the g file to a usercontrol base class and throws a compiler error saying the partial classes do not inherit the same base.  The same also happens if i make any changes to the page im working on.  If write a new element into the xaml and save the file it will reset the base class in the generated file.  This is basically causing me that every time i make a change i have to view all files, open up the g file and fix the base class again.  Is this a bug or is it never intended for a silverlight page to implement a base page?

Puts

Joined on 05-09-2008
Posts 4