Problems with CF2002 and Visual inheritance in a Wizard prototype

This week I was able to use Justin's excellent WinForms Wizard in some prototypes for handing state transition in a UI:

    http://weblogs.asp.net/justin_rogers/articles/120197.aspx

I wonder whether many people fall short in their understanding of when you might benefit from implementing a framework such as this.  Basically, you can benefit whenever you have a set of transitions, sequences or partial orderings which tell an 'unfolding story'.  Justin's framework already has rudimentary support for things such as named navigation and validation so, it's not hard to support any of these scenarios.

The most challenging part of my prototype was to implement this within the Compact Framework - especially given that one of my "must have" features was designer support for panels!  You can *nearly* do it... but, from what I can tell, not quite.  Well, technically that's not the whole story; you can do it by implementing each Panel as a Form.  I could live with that - and in fact I was pretty happy when I used forms and it worked :-) the problem is that, the designer apparently doesn't support derived Forms.  This means that, to get it working in the designer you'd either have to derive each panel from Form or, derive it from a base class which holds the IWizardPanel and IWizardNavigation implementations and change the derivation to Form whenever you want to step into the designer.  Neither of these are great options - especially the first one!

All up an interesting learning experience!

[ Currently Playing : Underwater Love (radio edit) - Smoke City - Various Artists - The Chillout Session 2 [UK] Disc 1 (04:31) ]

2 Comments

  • By CF2002 you clearly mean CF 1.0 :-)

    Agreed on all the problems with visual inheritance in VS2003 and smart device projects, look forward to proper support in VS2005 (and CF 2.0).

  • Had the same problems with the visual inheritance too. I got around it by declaring a Compilation Constant called DESIGN that was applied to a Configuration called Design. That way I could have my forms derive from System.Windows.Forms at design time, but when back in Debug configuration all was as it should be.



    Not very clean eh? Looking forward to VS2005

Comments have been disabled for this content.