Advanced Forum Search Results
-
Sorry
My mistake... I'd failed to spot that this question was posted in the SL 3 Beta forum.
-
Attached properties can be set on any type that derives from DependencyObject, regardless of their relationship to any other object.
So the short answer is yes, you can set an attached property onto a "grand child". The bad news is that the Grid won't read them, so all the grandchildren will end up in Row 0, Column ...
-
Triggers don't work in Silverlight 2 (with the exception of the Loaded trigger).
They work in WPF.
You'll need to find another way to tackle the problem, I'm afraid.
-
If you want the X position to be "instantly" snapped to a new value, use a DiscreteDoubleKeyFrame, rather than a SplineDoubleKeyFrame. With a Spline, you'll get an interpolated move (it's linear by default) over time; with Discrete it will move instantly when the keytime is reached.
-
No, absolutely not.
You can expose a single DP, whose type is the type of the enum. Then you will be able to set the value of that property to any of the values of the enum.
-
Simply put, you can't do this with Silverlight (easily).
You can
a. write a Windows Service (or startup program), that exposes a sockets or wcf service that is called from Silverlight (assuming that you can make the x-domain call, so make sure that you have an appropriate clientaccesspolicy.xml in place). You will then need to execute ...
-
The answer to your questions can be found by clicking the GetStarted link at the top of the page, and then follow the training videos that you will find there.
-
In the call to DependencyProperty.Register, make sure that the last parameter reads something like this
new PropertyMetadata( Foo.A )
assuming that you have an enum called Foo, with a named value A.
-
vivek_daramwai,
DataContext largely works very well in Silverlight 2.
I have the following XAML constructed
<UserControl>
<Grid>
<ContainerControl> <!-- a custom control of mine -->
<ChildControl Text="{Binding Path=Name}" /> <!-- another custom control of mine -->
...
-
A further thought has crossed my mind.
A common mistake to make when registering DPs is to leave in the default PropertyMetadata(0) in the DP.Register method. This will result in a TypeInitializationException at runtime, and potentially strange problems at design-time.
Make sure that you change this to a proper value of the enum, as the ...