By default, the AutoCompletion List will display to the left of its Target textbox.Left positions of both Textbox and AutoCompletionL ist is same.
Is there a way or CSS Settings to align the same to the right, so that both AutoCompletionL ist and TextBox end with same right positions.
I have AutoCompleteExt ender mapped for a TextBox. When the AutoCompleteLis t gets displayed, it is postioned to left same as TextBox left position, which is it's default behaviour.
As my AutoCompleteLis t has wide data, i want the list to right aligned with the textbox.
No style for textbox.
Below is the .aspx
Is there a way or CSS Settings to align the same to the right, so that both AutoCompletionL ist and TextBox end with same right positions.
I have AutoCompleteExt ender mapped for a TextBox. When the AutoCompleteLis t gets displayed, it is postioned to left same as TextBox left position, which is it's default behaviour.
As my AutoCompleteLis t has wide data, i want the list to right aligned with the textbox.
No style for textbox.
Below is the .aspx
Code:
<html xmlns="http://www.w3.org/1999/xhtml"> <head runat="server"> <title></title> <style> .completionListElement { background-color: ivory; color: black; border: solid 1px gray; cursor: pointer; font-family: Arial; font-size: 10pt; width: auto !important; } .listItem { } .highlightedListItem { background-color: Gray; color: Red; } .txt { background-repeat: no-repeat; background-position: right; } </style> </head> <body> <form id="form1" runat="server"> <cc1:ToolkitScriptManager runat="server" ID="tcm"> <Services> <asp:ServiceReference Path="~/WebService1.asmx" /> </Services> </cc1:ToolkitScriptManager> <table width="100%" border="1"> <tr> <td width="50%"> <asp:Button ID="Button1" runat="server" Text="Button" /> </td> <td width="50%" align="right"> <asp:TextBox runat="server" ID="txtComments"> </asp:TextBox> <cc1:AutoCompleteExtender ID="ace1" runat="server" TargetControlID="txtComments" CompletionListCssClass="completionListElement" CompletionListItemCssClass="listItem" CompletionListHighlightedItemCssClass="highlightedListItem" ServicePath="~/WebService1.asmx" ServiceMethod="HelloWorld" MinimumPrefixLength="3" EnableCaching="true" CompletionListElementID="divlist"></cc1:AutoCompleteExtender> <div id="divlist" runat="server"> </div> </td> </tr> </table> </form> </body> </html>
Comment