MaskedEditExtender(ASP.net AjaxControlToolkit ) ASP.NET Textbox copy and paste is not copy last digit RRS feed

  • Question

  • User-1778011532 posted

    Dear All,

    I have asp.net text box and MaskedEditExtender to get USA Phone no as input. it works fine.

    When I copy the data from the text box and paste it in same or similar control, the last digit was not copied. I think, it also copies parenthesis, so it is not pasting full no.

    I found that, if I copy the phone no to notepad / normal Text box and remove Bracket / Parenthesis, it copy full data.

    I want user to copy and just paste it. Can any one help me.

    <asp:TextBox ID="tbPhoneNum" runat="server" CssClass="BidsTextBox" Width="140px" MaxLength="13"></asp:TextBox>
    <cc1:MaskedEditExtender ID="PhoneTextBox" Mask="(999) 999-9999" MaskType="None" runat="server" ClearMaskOnLostFocus="false" TargetControlID="tbPhoneNum" />

    similarly for Fax input.

    when user copied from phone to fax or when two instance, copy from phone to phone. I face this problem.

    if user copy (121) 121-1212 and paste it 
    the value is (121) 121-121. last digit is missing
    if I copy 121 121-1212 without braces from normal text box / note pad then, it copy all digit.

    Can any one help me.



    Tuesday, March 31, 2015 12:57 PM

All replies

  • User1918509225 posted

    Hi thanjaipvr,

    I have tested your code in my side,when i type value in textbox with maskeeditextender like below:

    (121) 121-1212

    when i copy it into another textbox,it will show the same .

    If you don't mind,please share me your html page which can reproduce issue

    Best Regards,

    Kevin Shen

    Wednesday, April 1, 2015 5:47 AM
  • User-1778011532 posted

    Thanks Kevin.

    Did you copy to another text box with maskeeditextender of same pattern(ie phone no).

    Please share your code let me check it.



    Wednesday, April 1, 2015 10:53 AM