Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

113
Vistas
Regular expression for Alphanumeric comma separated strings containing one hyphen

I'm trying to create a regular expression containing the following rules:

  • can have comma-separated values but the comma cannot be at the start or at the end of the string;
  • must contain only alphanumeric values;
  • must contain one hyphen '-' in each one of the values

eg. 123-1234567 // ok

123-1234567,abc12-12345 // ok

1231234567 //NOT OK

123-1234567-123 //NOT OK

123-1234567,abc12-12345, //NOT OK

,123-1234567,abc12-12345 //NOT OK

I need to validate the string on client-side with javascript and c# on server-side.

about 4 years ago · Juan Pablo Isaza
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda