Expand|Select|Wrap|Line Numbers
- function upperCase(x)
- {
- try
- {
- var y=document.getElementById(x).value;
- document.getElementById(x).value=y.toLowerCase();
- }
- catch(Error)
- {
- }
- }
i am calling
Expand|Select|Wrap|Line Numbers
- <asp:TextBox ID="txtUrl" Width="450px" runat="server" Wrap="true" onkeyup="upperCase(this.id)" TextMode="MultiLine"></asp:TextBox>
but whenever i type anything withing typed text for eg. if the textbox already have string "texttexttext" n if i try to modify the middle character then on upperCase function call the the function male the character to lowercase in then cursor position goes to end of the text... so i am not able to type anything in the middle... so what is the option to preserve the cursor position at it is which was befor..