cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
3csman
Impactful Individual
Impactful Individual

Enforce 'Sentence Case'

How do I enforce 'Sentence Case' in a form datacard?

 

This is what could be used in a Label or Text Input.

 

     Proper(Source.Text)

 

Where would the above go in a datacard field to enforce 'Sentence Case' data entry?

25 REPLIES 25
3csman
Impactful Individual
Impactful Individual

Field Validating:

Card: MemberEmail;

Data Card: UpdateFormMemberEmailFld

 

Validation Toggle Name: EditMemberProfileValidationToggle

RandyHayes
Super User
Super User

@3csman 

So, normally you would have the accounting of the IsBlank in your toggle validator.

So, in that Default formula of the toggle, something like : 

   !(IsBlank(TextInputControlFromDataCard.Text) || IsMatch(TextInputControlFromDataCard.Text, Email))

This will be true if the textinput has something in it and it is not a valid email.

It will be false if the textinput is blank (matching to email is irrelevant at that point) 

 

Then, your BorderColor can be based off of that formula as well.

If( !(IsBlank(TextInputControlFromDataCard.Text) || IsMatch(TextInputControlFromDataCard.Text, Email)), Red, Black)

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up below. Solved your problem? - Click on Accept as Solution below. Others seeking the same answers will be happy you did.
Check out my PowerApps Videos too! And, follow me on Twitter @RandyHayes

Really want to show your appreciation? Buy Me A Cup Of Coffee!

View solution in original post

3csman
Impactful Individual
Impactful Individual

Is 'Match.Any' the right choice here? I don't get errors, but I'm not sure it correct.

 

If( !(IsBlank(UpdateFormUnqIDFld.Text) || IsMatch(UpdateFormUnqIDFld.Text, Match.Any)), Red,Black)

 

Data Card (UpdateFormUnqIDFld) Text Input field in a Form.

3csman_0-1613677856488.png

 

RandyHayes
Super User
Super User

@3csman 

No, before you were validating an Email, what kind of validation are you trying to do on this text input?

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up below. Solved your problem? - Click on Accept as Solution below. Others seeking the same answers will be happy you did.
Check out my PowerApps Videos too! And, follow me on Twitter @RandyHayes

Really want to show your appreciation? Buy Me A Cup Of Coffee!
3csman
Impactful Individual
Impactful Individual

I understand.

 

Here is what is in the toggle for the field.

 

    IsMatch(UpdateFormUnqIDFld.Text, "[A-Z]{2}[0-9]{4}")))

 

The field now has the following in it; does this work?

 

     If( !(IsBlank(UpdateFormUnqIDFld.Text) || IsMatch(UpdateFormUnqIDFld.Text, "[A-Z]{2}[0-9]{4}")), Red,Black)

RandyHayes
Super User
Super User

@3csman 

Yes, that should work.  Is it working as you want?

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up below. Solved your problem? - Click on Accept as Solution below. Others seeking the same answers will be happy you did.
Check out my PowerApps Videos too! And, follow me on Twitter @RandyHayes

Really want to show your appreciation? Buy Me A Cup Of Coffee!

Helpful resources

Announcements
PA_User Group Leader_768x460.jpg

Manage your user group events

Check out the News & Announcements to learn more.

secondImage

Power Apps Community Call

Please join us on Wednesday, October 20th, at 8a PDT. Come and learn from our amazing speakers!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

Welcome Super Users.jpg

Super User Season 2

Congratulations, the new Super User Season 2 for 2021 has started!

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

Top Solution Authors
Top Kudoed Authors
Users online (2,430)