
How to enumerate every control in a composite Control
What eaxctly are you trying to do? You want the composite control to
enumerate all the controls it hosts? Well, you should know up front what
controls it hosts - you have placed them in the dialog editor. If you
want to do it programmatically for some reason, enumerate all child
windows with EnumChildWindows, call AtlAxGetControl on each.
Or do you want to support the ability for a hosted control to enumerate
all sibling controls? In this case you need to implement IOleContainer,
and pass your implementation of it via IObjectWithSite::SetSite (ATL
hosting window implements IObjectWithSite, you get to it with
AtlAxGetHost) to each host support window.
--
With best wishes,
Igor Tandetnik
"For every complex problem, there is a solution that is simple, neat,
and wrong." H.L. Mencken
Quote:
> I am developing a Composite ActiveX Control in ATL,But I don't know
to
> enumerate every contrl in the Composite Control.
> If you know ,Please Tell me to compose a Email to me.