Dec 6, 2010

Auto complete CSS in asp.net

Please find below CSS and HTML for autocompltet extender please use as needed...

also please change color as per your color scheme

For Autoextender CSS

/*auto extender starts */



.AutoCompleteExtender_
CompletionList
{
background-color : window; color : windowtext; padding : 1px; font-size: 12px; background-color:Gray;
/*creates border with autocomplete_completionListElement background-color*/
}

/*AutoComplete flyout */
.AutoCompleteExtender_CompletionListItem
{text-align : left; background-color:White;}

/* AutoComplete highlighted item */
.AutoCompleteExtender_HighlightedItem { background-color: Silver; color: windowtext; font-weight:bold; font-size: small;}




.AutoExtender
{
font-family: arial;
font-size: 12px;
font-weight: normal;
border: solid 1px #419448;
line-height: 20px;
padding: 10px;
background-color: White;
margin-left:0px;
margin:0px;

}
.AutoExtenderList
{
border-bottom: dotted 1px #419448;
cursor: pointer;
color: #144a19;
}
.AutoExtenderHighlight
{
color: White;
background-color: #714F10;
cursor: pointer;
}
#divwidth
{
width: 150px !important;
}
#divwidth div
{
width: 150px !important;
}

/*auto extender CSS ends */


//auto compltet extender HTML
CompletionSetCount="20" EnableCaching="false" FirstRowSelected="True" MinimumPrefixLength="1"
ServiceMethod="GetSuburbTest" ServicePath="WebService.asmx" TargetControlID="txtBillSuburb"
CompletionListCssClass="AutoExtender"
CompletionListItemCssClass="AutoExtenderList"
CompletionListHighlightedItemCssClass="AutoExtenderHighlight"
CompletionListElementID="divwidth">

1 comment: