On Tuesday, March 06, 2012 01:48:26 PM Ed Leafe wrote: > On Mar 6, 2012, at 1:27 PM, Paul McNett wrote: > > The examples you cite do not, in and of themselves, suggest making a > > subclass in Dabo, although they sure did in VFP. > > While it's certainly easier to do in Dabo, I tend to be lazy. If I have > to > add dozens of controls with the same changes across many forms, I'd rather > define the subclass once and then use that in all my forms. > > hs.append(dabo.ui.dTextBox(self, DataField="name", **dataCtrlProps)) > > I prefer the properties parameter rather than the ** form: > > hs.append(dabo.ui.dTextBox(self, DataField="name", > properties=dataCtrlProps)) > > They both work the same, but that's what that parameter was created for. > > > > -- Ed Leafe
STyler, Just reading the answers should tell you a lot. Ed's way still uses the base class but changes the properties. Sounds like he was concerned with maintaining a consistent UI. Sound's like Paul's situation is different where he needed a special action to occur - so he built a special sub-class of two (maybe more) base class controls - but still uses Dabo base classes. In my case I too required a special action associated with a Dabo base class. Just proves that Dabo's base classes are flexible and usable for most cases. Johnf _______________________________________________ Post Messages to: Dabo-users@leafe.com Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users Searchable Archives: http://leafe.com/archives/search/dabo-users This message: http://leafe.com/archives/byMID/5973533.DkCP9fEona@linux-12