This is a migrated thread and some comments may be shown as answers.

[Solved] width and height of combobox increasing in disable mode.

5 Answers 178 Views
ComboBox
This is a migrated thread and some comments may be shown as answers.
Jojy
Top achievements
Rank 1
Jojy asked on 03 Apr 2009, 10:02 PM
I have a radcombobox with a fixed height and width.
in some cases I need to make the property enabled="false" in prerender.
Combobox is getting disabled but the height and width is increasing.
After this I noticed that if I fire any other events combobox will be in normal height and width.
skin used is "default".
do I need to make any changes in 

.ComboBoxItemDisabled_Default in the script.
I am using IE-7

PLease help me to get the normal height and width of radcombobox.

Thanks
Jojy

5 Answers, 1 is accepted

Sort by
0
Kamen Bundev
Telerik team
answered on 06 Apr 2009, 03:21 PM
Hello Jojy,

I can't reproduce your issue here - the RadComboBox is not getting any bigger if disabled on PreRender. However there was a bug in RadComboBox with AllowCustomText="true" which was rendering the arrow side broken. This bug is now fixed and you can get it with the next internal build. If however your RadComboBox is still getting bigger, could you please provide a sample project or a live URL where we can reproduce this?

Kind regards,
Kamen Bundev
the Telerik team

Check out Telerik Trainer , the state of the art learning tool for Telerik products.
0
Jojy
Top achievements
Rank 1
answered on 06 Apr 2009, 04:33 PM
Kamen Bundev ,
Thanks for your reply.
I am sending the codes.
my html code for combo is :
<rad:RadComboBox ID="radcboVendor1" runat="server" AllowCustomText="True"
DataTextField="VendorX" DataValueField="Id" MarkFirstMatch="True"
AutoPostBack="True"
onselectedindexchanged="radcboVendor1_SelectedIndexChanged" Skin="Default"
TabIndex="1">
</rad:RadComboBox>

Code In Prerender
LoadCombobox();
radcboVendor1.SelectedValue = Request.QueryString["Id"];
radcboVendor1.Enabled = false;
 
Script used for default is
/* RadComboBox default embedded skin */
.ComboBoxDropDown_Default
{
scrollbar-face-color: #e9e9e9;
scrollbar-highlight-color: #ffffff;
scrollbar-shadow-color: #e9e9e9;
scrollbar-3dlight-color: #dbdbdb;
scrollbar-arrow-color: #787878;
scrollbar-track-color: #f5f5f5;
scrollbar-darkshadow-color: #aeaeae;
border: 1px solid #626262;
background: #fff;
width: auto;
text-align: left;
}
.ComboBoxInput_Default
,
.ComboBoxInputHover_Default
{
height: 23px; /*only IE applies this*/
vertical-align: middle;
border: 1px solid #626262;
cursor: default;
padding: 3px 5px;
font: normal 12px "Arial", sans-serif;
}
.ComboBoxInputHover_Default
{
background-color: #efefef;
}
.ComboBoxItem_Default
,
.ComboBoxItemHover_Default
{
font: normal 11px "Arial", sans-serif;
cursor: default;
color: #333;
padding: 5px;
zoom: 1;
}
.ComboBoxItemHover_Default
{
background-color: #007356;
color: #fff;
}
.ComboBoxImage_Default
,
.ComboBoxImageHover_Default
{
vertical-align:middle;
}
.ComboBoxHeader_Default
{
background-color: #929292;
color: #fff;
font: bold 11px Arial, sans-serif;
}
.ComboBoxHeader_Default
td
{
border-right: 1px solid #5f5f5f;
text-indent: 5px;
}
.ComboBoxItemDisabled_Default
{
font: normal 11px "Arial", sans-serif;
color: #ccc;
cursor: default;
padding: 5px;
}
.ComboBoxLoadingMessage_Default
{
font: normal 12px "Arial", sans-serif;
}
.ComboBoxMoreResultsMessage_Default
{
color: #999;
text-align: center;
padding: 3px 0;
font-size: 10px;
}
.ComboBoxMoreResultsImage_Default
{
padding: 5px 0 0 0;
}
.ComboBoxMoreResultsBox_Default
{
background: #f3f3f3;
}
 
Dll used is RadComboBox.Net2.dll version is 2.8.4.0.
Is there any way to attach screen shot.
I tried by changing the skin to webBlue same issue exists.

Please help
Jojy
 
0
Jojy
Top achievements
Rank 1
answered on 06 Apr 2009, 10:29 PM
Hello Kamen Bundev,
I had created a sample application.   
http://www.easy-share.com/1904393344/SampleProject.zip


Thanks
Jojy
0
Accepted
Kamen Bundev
Telerik team
answered on 07 Apr 2009, 11:28 AM
Hi Jojy,

Add this CSS to your project in order to fix this issue:
.ComboBox_Default .ComboBoxInput_Default
{
    height: 15px;
}


The problem is that you can't modify with javascript a disabled control in IE. Alternatively you can probably fix it by disabling the control after it has been rendered.

Let me know if this helps.

All the best,
Kamen Bundev
the Telerik team

Check out Telerik Trainer , the state of the art learning tool for Telerik products.
0
Jojy
Top achievements
Rank 1
answered on 07 Apr 2009, 02:23 PM
Hi Kamen Bundev,
Thanks a lot its working now.

Jojy
Tags
ComboBox
Asked by
Jojy
Top achievements
Rank 1
Answers by
Kamen Bundev
Telerik team
Jojy
Top achievements
Rank 1
Share this question
or