simple multiline edit ctrl
-
Here's an easy one that's been bugging me: I've got some edit controls in a dialog, and I checked the multiline box, and I'm hoping that when the user types past the end of a line, it will wrap around, much as it is doing while I type at this precise moment;) Anyway, even if there are some dwStyle flags I could use, how can I set those since Create is never called for dialog controls? thanks, Jake
-
Here's an easy one that's been bugging me: I've got some edit controls in a dialog, and I checked the multiline box, and I'm hoping that when the user types past the end of a line, it will wrap around, much as it is doing while I type at this precise moment;) Anyway, even if there are some dwStyle flags I could use, how can I set those since Create is never called for dialog controls? thanks, Jake
You can change control styles in OnInitDialog() - the controls are all created at that point, just not visible yet. --Mike-- http://home.inreach.com/mdunn/ "Make sure that if you are using a blow torch that you don't set anything on fire." -- Chris Maunder
-
You can change control styles in OnInitDialog() - the controls are all created at that point, just not visible yet. --Mike-- http://home.inreach.com/mdunn/ "Make sure that if you are using a blow torch that you don't set anything on fire." -- Chris Maunder
Right, but how do I change the control styles? CEditCtrl didn't seem to have a SetStyle function, but if it did I would try to add the ES_WANTRETURN style? A little more specific please? X| thanks, Jake
-
Here's an easy one that's been bugging me: I've got some edit controls in a dialog, and I checked the multiline box, and I'm hoping that when the user types past the end of a line, it will wrap around, much as it is doing while I type at this precise moment;) Anyway, even if there are some dwStyle flags I could use, how can I set those since Create is never called for dialog controls? thanks, Jake
Set "Multiline", but remove "Auto HScroll". If you want to change style bits at runtime, add a CEdit variable associated with the edit control to your dialog class, and use ModifyStyle() function. Paolo ------ "airplane is cool, but space shuttle is even better" (J. Kaczorowski)