Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7793991
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 1, 20262026-06-01T22:39:44+00:00 2026-06-01T22:39:44+00:00

i need to control the numer of characters enter by the user on a

  • 0

i need to control the numer of characters enter by the user on a single textbox, but i don’t know how, for example y have this

$.validator.addMethod('selectNone',
                    function(value, element) {
                        return this.optional(element) ||
                        (value.indexOf(" ") == -1);
                    }, "Por Favor Selecciona una Opción");

how can i create a rule that control that the use just enter 6 characters (alfanumeric) and how can i control that the user can enter max a number 999,999,999.99 (i can control that the user if doesnt enter the “,” and my textbox add it when the user finish a number like 55555.55 and transform it to 55,555.55 (the “.” should be always entered by the user if they are going to enter decimals)

thanks

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-01T22:39:45+00:00Added an answer on June 1, 2026 at 10:39 pm

    Is this actually 2 questions? how to limit the number of chars and how format what the user has entered.

    You can limit the length just in HTML by using the maxlength property on the input element

    <input type="text" id="YourTextbox" name="YourTextbox" maxlength="20" />
    

    For the formatting have a look at this question…
    Add comma to numbers every three digits

    Also – if you’re using JQuery validator http://docs.jquery.com/Plugins/Validation/Methods/maxlength

    For the regex – have a look at this question too Insert commas into number string

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I need to create control to draw border around its child. So, I have
I'm using a TextBox control and want the characters to turn red after a
I need a WPF Textbox that displays a phone number as (555) 555-5555 but
I have some data I need to present to a user in a very
I have a need for an html control with fixed number of columns that
I need to have a user select their address in our address database (I'm
I don't know if the follow code snippet intend to work in this way,
I have a user control with a number of methods. I also have a
I need a SMALL/LIGHTWEIGHT DB control (maybe delivered as a single PAS file) that
I have a logger that listens to sequences such as equations, but I need

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.