Connecting Tech Pros Worldwide Forums | Help | Site Map

Ordering two controls that dock "top"?

Brett Romero
Guest
 
Posts: n/a
#1: Mar 29 '06
I have an MDI Parent form with a toolstrip and menustrip. The
menustrip is always the top most. Both are Docked to Top. I
contemplated using a toolstripcontainer but then removed it. I had to
redock my toolstrip and menustrip. Now the toolstrip is always top
most. I added a new MDI Parent form and can't find any differences.
How do I get the menustrip to be top most?

Also, is there a way to get the menu strip items (opening of a menu) to
be transparent, such as this:
http://www.windowsforms.net/WhidbeyF...4&Cat=Controls

Thanks,
Brett


Larry Lard
Guest
 
Posts: n/a
#2: Mar 30 '06

re: Ordering two controls that dock "top"?



Brett Romero wrote:[color=blue]
> I have an MDI Parent form with a toolstrip and menustrip. The
> menustrip is always the top most. Both are Docked to Top. I
> contemplated using a toolstripcontainer but then removed it. I had to
> redock my toolstrip and menustrip. Now the toolstrip is always top
> most. I added a new MDI Parent form and can't find any differences.
> How do I get the menustrip to be top most?[/color]

Between multiple controls that are Docked in the same place, it's the
Z-Order that decides the order they dock in. In the visual designer,
use (right click) Send to Back / Bring to Front; in code, use
Control.SendToBack / .BringToFront. It's not intuitively (to me,
anyway) obvious which way round is which, so play with it till it makes
sense :)

[color=blue]
> Also, is there a way to get the menu strip items (opening of a menu) to
> be transparent, such as this:
> http://www.windowsforms.net/WhidbeyF...4&Cat=Controls[/color]

You want the actual menu strip to be transparent? Hmm, don't think you
can do that. It might look a bit odd?

--
Larry Lard
Replies to group please

Brett Romero
Guest
 
Posts: n/a
#3: Mar 30 '06

re: Ordering two controls that dock "top"?


Z-Order doesn't affect which control will dock top most.

I want the menu that opens when a user clicks a menu strip item to be
transparent. So no transparency until the user does something. The
actual always visible menu strip will remain non transparent. I think
you are correct though in that it cannot be done.

Thanks,
Brett

Brett Romero
Guest
 
Posts: n/a
#4: Mar 30 '06

re: Ordering two controls that dock "top"?


I stand corrected. The one you want to be top most should have the
lower Z Order, which means furtherest back. It seems backwards to me
and I discovered it by accident.

Brett

Closed Thread


Similar C# / C Sharp bytes