I have a single line of text field on a portal Entity Form / Basic Form. This field is not a required field.
I create an Entity Form Metadata / Basic Form Metadata record for the attribute.
In the "Regular Expression" field I put in: ^[0-9]*$
In the "Regular Expression error message" field I put in: SEC must contain numeric characters only.
I open the form in the portal. The field is blank. It correctly does not have the red asterisk as the field is not required.
As soon as I type a value in the field, the red asterisk appears.
When I remove the value from the field, the red asterisk magically appears.
Is this a bug? Is it a "feature"? Is it just happening to me?
Portals version: 9.3.11.12
FYI: Microsoft confirmed bug. Hopefully be fixed in upcoming portal release.
"With regard to the issue with the help of DEV team we were able to reproduce the issue on the vanilla portal on our side and also identified this as a BUG, our PG team is currently working on the fix for the issue and there is no exact estimated time as of now provided for the fix release."
Hi @CVO
As @chleverenz pointed out. It is a bug. You can raise a ticket to Microsoft and let's see their response. just in case if you want to get rid of the asterisk. (So Annoying) then below is the steps
In portal studio:
1. Add custom.css file and add the following CSS
#RegularExpressionValidatorcr5ce_lastname{
visibility: hidden !important;
}
2. once done save> Sync config> Browse the website> Ctrl + F5 ( hard refresh) to hide the asterisk.
Hope it helps.
------------
If you like this post, give it a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users to find it.
Hi @CVO ,
just checked it in one of my portals - same behaviour. But when i leave it empty and tab out, the asterisk is cleard 🙂
so, seems to be a bug 😞
Have fun,
Christian
Thanks for your response Christian. Just to be clear, this is not about the Regex validation passing or failing on null values. The Regex is working perfectly and is throwing a validation error when the form is submitted and the value does not produce a match on the Regex expression.
This post is specifically about the red asterisk (or the required marker) * appearing or disappearing on the non-required field whenever text is entered or removed in the field (and before the form is even submitted).
The red asterisk is governed by the checkbox "Field is required" in the Entity Form Metadata record. This is unchecked. However, the field magically displays the required indicator in the portal as soon as text is entered in to the field. This does not happen normally, and it appears the circumstances that lead to this happening are when a regular expression (of any sort) is entered in to the "Regular Expression" field in the Entity Form Metadata record.
Hi @CVO ,
did not test, but may be null or undefined is passed in to the regexp and the test fails.
In case there are blanks in, may be this regexp helps: ^[0-9]*$|^\s*$ - in case of null i have no good idea, would be a bug...
May be this points in the right direction,
Christian
Lucas001
60
Super User 2025 Season 2
Fubar
55
Super User 2025 Season 2
surya narayanan
35