Hello,
I'm trying to create a custom DataFormDataField by inheriting from it. my goal is to create something similar to the DataFormDateField or CheckboxField or whatever, for different types of controls that are used as the content template.
I tried several approaches, both defining a style setting the content template and setting the style in the constructor and defining a data template as a resource and setting that in the constructor. The derived control would define certain DependencyProperties similar to the ones of the contained control which the control in the datatemplate would then bind to by FindAncestor binding.
Aside form the difficulties of locating that resource in Silverlight, I'm not getting very far. For some reason the content template does not seem to have any effect. I always see the default DataFormDataField look.
How did you create the custom DataFormDataField implementations and what is the recommended way to implement one like those, say for a RadNumericUpDown or a passwordBox or AutoCompleteBox or whatever?
Any help with a concrete example would be very much appreciated.
I'm trying to create a custom DataFormDataField by inheriting from it. my goal is to create something similar to the DataFormDateField or CheckboxField or whatever, for different types of controls that are used as the content template.
I tried several approaches, both defining a style setting the content template and setting the style in the constructor and defining a data template as a resource and setting that in the constructor. The derived control would define certain DependencyProperties similar to the ones of the contained control which the control in the datatemplate would then bind to by FindAncestor binding.
Aside form the difficulties of locating that resource in Silverlight, I'm not getting very far. For some reason the content template does not seem to have any effect. I always see the default DataFormDataField look.
How did you create the custom DataFormDataField implementations and what is the recommended way to implement one like those, say for a RadNumericUpDown or a passwordBox or AutoCompleteBox or whatever?
Any help with a concrete example would be very much appreciated.