to validate hex value with regex you can use this snippet.
Sample RegEx
^#?([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$
this regex will match:
#112233
#FF1122
#aaffDD
All the Code Snippets and Samples you need
to validate hex value with regex you can use this snippet.
^#?([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$
this regex will match:
#112233
#FF1122
#aaffDD
You must be logged in to post a comment.
RT @CodeSnippetsNET: How to validate hex value with #regex http://t.co/rVmbU8XYKq #code #programming #coding