cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
rliam
Level: Powered On

Adding a minimum to a number field

I set up a form that has a user input an account number. I set a maximum so it cannot go over 10 digits. However, I need to set a minimum at 10 so they don't submit a partial account number.

1 ACCEPTED SOLUTION

Accepted Solutions
Super User
Super User

Re: Adding a minimum to a number field

Easiest way to control that is to set your submit button based on the validation of that field.

 

Example:  On the DisplayMode property of your submit button:

   If(Len(textInputField.Text)<>10, Disabled, Edit)

 

This way the button is not available unless they have a valid length number.

Might also want to consider changing the back color of the field or making a label visible if the length is not 10.

 

Hope that helps.

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up. Solved your problem? - Click on Accept as Solution. Others seeking the same answers will be happy you did.
1 REPLY 1
Super User
Super User

Re: Adding a minimum to a number field

Easiest way to control that is to set your submit button based on the validation of that field.

 

Example:  On the DisplayMode property of your submit button:

   If(Len(textInputField.Text)<>10, Disabled, Edit)

 

This way the button is not available unless they have a valid length number.

Might also want to consider changing the back color of the field or making a label visible if the length is not 10.

 

Hope that helps.

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up. Solved your problem? - Click on Accept as Solution. Others seeking the same answers will be happy you did.

Helpful resources

Announcements
firstImage

PowerApps Monthly Community Call!

Join us next Wednesday for our Demo Extravaganza, October 16, 2019 8am PDT.

firstImage

Microsoft Business Applications Virtual Launch Event

Join us for an in-depth look at the new innovations across Dynamics 365 and the Microsoft Power Platform.

firstImage

Watch Sessions On Demand!

Continue your learning in our online communities.

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

FirstImage

Power Platform World Tour

Coming to a city near you

thirdimage

PowerApps Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

FourthImage

Join PowerApps User Group!!

Connect, share, and learn with your peers year-round

SecondImage

Power Platform Summit North America

Register by September 5 to save $200

Top Kudoed Authors
Users Online
Currently online: 399 members 5,444 guests
Please welcome our newest community members: