This question is locked. New answers and comments are not allowed.
Hi,
Does the RadTabControl not work with VisualStates?
I have several tabs with different content in them and using Expression Blend modified a Visual State so that on one of the RadTabItems a child buttons visibility is set to collapsed in order to hide it.
I find that this can cause exceptions to be thrown in Expression Blend when I move to a different tab. Within the application I am using property triggers and GoToStateAction class to change to the visual state. When this happens I get a first chance exception - InvalidOperationException : 'Cannot Resolve TargetName btnSaveCertificates'.
Looking through the telerik documentation it seems that the reason for this is that as the user moves between tabs it is only the active tab whose content is displayed and part of the Visual Tree because only a single content presenter is being used by the RadTabControl. Hence even though the button to be hidden is visible within the xaml, it is only part of the Visual Tree when its parent Tab is active.
I have looked at the IsContentPreserved property of the RadTabControl setting it to true, but when I run the application the tabs contents are blank. Is the idea behind this property that all of the TabItems content is loaded into the VisualTree so that it can be accessible by VisualStates?
Please advise.
Cheers
pb
Does the RadTabControl not work with VisualStates?
I have several tabs with different content in them and using Expression Blend modified a Visual State so that on one of the RadTabItems a child buttons visibility is set to collapsed in order to hide it.
I find that this can cause exceptions to be thrown in Expression Blend when I move to a different tab. Within the application I am using property triggers and GoToStateAction class to change to the visual state. When this happens I get a first chance exception - InvalidOperationException : 'Cannot Resolve TargetName btnSaveCertificates'.
Looking through the telerik documentation it seems that the reason for this is that as the user moves between tabs it is only the active tab whose content is displayed and part of the Visual Tree because only a single content presenter is being used by the RadTabControl. Hence even though the button to be hidden is visible within the xaml, it is only part of the Visual Tree when its parent Tab is active.
I have looked at the IsContentPreserved property of the RadTabControl setting it to true, but when I run the application the tabs contents are blank. Is the idea behind this property that all of the TabItems content is loaded into the VisualTree so that it can be accessible by VisualStates?
Please advise.
Cheers
pb