Hello,
I am attempting to dynamically set the width of a RadMaskedTextBox in codebehind. Everything was working fine until I decided to use custom css styling and set EnableEmbeddedBaseStylesheet="false". Once the property is set I can no longer change the width of the control in any way except through a linked style sheet. Which again doesn't work because I am setting the width dynamically in codebehind. Using the Width="XXpx" property or the Style="width: XXpx;" they are both ignored and the width of the control set to the default value.
Additionally the property EnableEmbeddedBaseStylesheet seems to have some odd behavior. I am setting it at the individual control level, so as a property of an individual RadMaskedTextBox. However if I don't set the property to false for any RadMaskedTextBox on the same page or intentionally set it to True for any one of the controls on the page then they ALL get set to true and the individual controls that have the property set to false are ignored.
Is there some way around this issue? My overall goal is simple: Use custom styling on the RadMaskedTextBox control and be able to dynamically control the width of the control at run time. Although to be clear setting the width or style properties inline at design time still doesn't work with the EnableEmbeddedBaseStylesheet property set to false.
Thank you,
Jeremy
----- CODE SNIPPET & CORRESPONDING IMAGE FILES -----
See Image1.png for rendered results
See Image2.png for rendered results
I am attempting to dynamically set the width of a RadMaskedTextBox in codebehind. Everything was working fine until I decided to use custom css styling and set EnableEmbeddedBaseStylesheet="false". Once the property is set I can no longer change the width of the control in any way except through a linked style sheet. Which again doesn't work because I am setting the width dynamically in codebehind. Using the Width="XXpx" property or the Style="width: XXpx;" they are both ignored and the width of the control set to the default value.
Additionally the property EnableEmbeddedBaseStylesheet seems to have some odd behavior. I am setting it at the individual control level, so as a property of an individual RadMaskedTextBox. However if I don't set the property to false for any RadMaskedTextBox on the same page or intentionally set it to True for any one of the controls on the page then they ALL get set to true and the individual controls that have the property set to false are ignored.
Is there some way around this issue? My overall goal is simple: Use custom styling on the RadMaskedTextBox control and be able to dynamically control the width of the control at run time. Although to be clear setting the width or style properties inline at design time still doesn't work with the EnableEmbeddedBaseStylesheet property set to false.
Thank you,
Jeremy
----- CODE SNIPPET & CORRESPONDING IMAGE FILES -----
<
telerik:RadMaskedTextBox
ID
=
"RadMaskedTextBox2"
runat
=
"server"
Text
=
"RadMaskedTextBox2"
Mask
=
"aaaaaaaaaaaaaaaaa"
EnableEmbeddedSkins
=
"false"
EnableEmbeddedBaseStylesheet
=
"False"
width
=
"80px"
/>
<
br
/>
<
telerik:RadMaskedTextBox
ID
=
"RadMaskedTextBox1"
runat
=
"server"
Text
=
"RadMaskedTextBox1"
Mask
=
"aaaaaaaaaaaaaaaaa"
EnableEmbeddedSkins
=
"false"
EnableEmbeddedBaseStylesheet
=
"false"
/>
<
telerik:RadMaskedTextBox
ID
=
"RadMaskedTextBox2"
runat
=
"server"
Text
=
"RadMaskedTextBox2"
Mask
=
"aaaaaaaaaaaaaaaaa"
EnableEmbeddedSkins
=
"false"
EnableEmbeddedBaseStylesheet
=
"True"
width
=
"80px"
/>
<
br
/>
<
telerik:RadMaskedTextBox
ID
=
"RadMaskedTextBox1"
runat
=
"server"
Text
=
"RadMaskedTextBox1"
Mask
=
"aaaaaaaaaaaaaaaaa"
EnableEmbeddedSkins
=
"false"
EnableEmbeddedBaseStylesheet
=
"false"
/>