Question

My textbox has MaskedEditExtender, but the problem is that when user clicks on the textbox, the cursor is positioned at end (right side) rather than the left side begning. Can someone help? There were some solution to have a java script function on onfocus, but ASP.net text does not have onfoucs event to be set.

<asp:TextBox ID="TextBox5" runat="server" CssClass="MainContent" ValidationGroup="MKE" Width="180px" />
                                        <asp:MaskedEditExtender ID="MaskedEditExtender2" runat="server"
                                            AcceptNegative="Left"  MaskType="Date" DisplayMoney="Left" ErrorTooltipEnabled="True" 
                                            mask="9999/99/99" MessageValidatorTip="true"  InputDirection="RightToLeft" CultureName="sv-SE" 
                                            OnFocusCssClass="MainContent" OnInvalidCssClass="MainContent" 
                                            TargetControlID="TextBox5"   />
Was it helpful?

Solution

I think the problem comes from the property InputDirection... Try

InputDirection="LeftToRight"
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top