AmbientDisplayName()
Mike Bryga -- MBryga@PickSys.com Wednesday, January 15, 1997 Environment: MSVC 4.0, Win95/NT 4.0 I have subclassed the Edit Box control using AppWizard, and am having = some difficulty with AmbientDisplayName(). I would like to save the display name in a member variable ASAP. = However, in the controls constructor it returns a null string. When is = AmbientDisplayName() valid? in what function am I best to save it? At design time, I want to use the AmbientDisplayName() for the text = property. Without doing anything to set this property, InternalGetText() = in OnDraw() returns the true display name. Great, but how did it get = set? Does COleControl manage design v.s. run time differences in the = stock caption/text property? Thanks, Mike
Julius Hamelberg -- jhamelberg@dca.com Friday, January 17, 1997 You should do it in the overridden virtual function: virtual void OnResetState( ); Take a look at this function in the help. ---------- From: Mfc-l@netcom.com Sent: Friday, January 17, 1997 6:36 AM Subject: AmbientDisplayName() Environment: MSVC 4.0, Win95/NT 4.0 I have subclassed the Edit Box control using AppWizard, and am having = some difficulty with AmbientDisplayName(). I would like to save the display name in a member variable ASAP. = However, in the controls constructor it returns a null string. When is = AmbientDisplayName() valid? in what function am I best to save it? At design time, I want to use the AmbientDisplayName() for the text = property. Without doing anything to set this property, InternalGetText() = in OnDraw() returns the true display name. Great, but how did it get = set? Does COleControl manage design v.s. run time differences in the = stock caption/text property? Thanks, Mike --------------- End of text item ---------------
| Вернуться в корень Архива |