Skip to main content
Home Forums Silverlight Programming Silverlight Controls and Silverlight Toolkit Popup Control
3 replies. Latest Post by varshavmane on July 2, 2009.
(0)
slen
Member
10 points
59 Posts
07-02-2009 12:11 AM |
What is the attribute to disable the parent control/graying the background once the popup button is clicked? I don't see any attribute to do it?
Thanks
tanmoy.r
Contributor
3594 points
710 Posts
07-02-2009 12:35 AM |
There are many ways of doing it.
1. Create a grid with black background and Opacity=0.2 (or as you like) at the end of you main page but before the popup control. So it lays over all of your controls except the popup. by default it will be hidden (Visibility=Collapsed) and when you open popup make it visible. It will grays out and disable the parent.
2. You can have IsHitTestVisible=False in the parent controls so it will not take any mouse actions. But it wont grays out the parent.
3. If you are using Silverlight 3 applications you can create child controls that pops up and grays out and disabled the parent.
07-02-2009 12:58 AM |
I am using silverlight 2.
I am interested in #1. Can you give me an example?
My seems like doesn't work. I put the opacity in my parent control. When I call my popup, I set the visibility = visible of my parent.
Too bad it turn white...
What opacity number should I put in? should I have the opacitymask?
varshavmane
6723 points
1,580 Posts
07-02-2009 1:23 AM |
Check your post for Model Control, I have converted the class in VB. Here is the link:
http://silverlight.net/forums/p/105266/240185.aspx#240185
If you use the following class it will automatically make your parent control gray.
If you still have any problem then let me know as I have used this Class and its works perfectly fine for me.
HTH