cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
DAVIDPOWELL
Post Prodigy
Post Prodigy

checking for required fields based on previous question

I'm trying to capture required fields. That have to be filled in.

 

Trying to get my IF statement to work.


I'm having trouble with required fields based on a previous selection.
i.e.

2a_txt_OpportunityAmount cant be blank.
IF 2a_txt_OpportunityAmount is answered "yes"


2b_txt_OpportunityAmount must be filled in also


If(IsBlank('1a_drop_CustomerName'.Selected.Value),Notify("The Federal/Public Sector Government Customer is a required field",Error)
,IsBlank('1b_drop_Corporate_Account'.Selected.Value),Notify("The Corporate Account is a required field",Error)
,IsBlank('2a_txt_OpportunityAmount'.Text),Notify("The Product Amount is a required field.",Error)


,UpdateContext({showDialog:true})
)
;

 

Thanks

Dave

1 ACCEPTED SOLUTION

Accepted Solutions
rubin_boer
Super User
Super User

hi @DAVIDPOWELL try 

 

If(And(2a_txt_OpportunityAmount.Text="yes",!IsBlank(2b_txt_OpportunityAmount.Text)),true) for 

2a_txt_OpportunityAmount cant be blank.
IF 2a_txt_OpportunityAmount is answered "yes"

2b_txt_OpportunityAmount must be filled in also

 

Further consider changing to a Switch statement

 

Hope this helps

 

View solution in original post

1 REPLY 1
rubin_boer
Super User
Super User

hi @DAVIDPOWELL try 

 

If(And(2a_txt_OpportunityAmount.Text="yes",!IsBlank(2b_txt_OpportunityAmount.Text)),true) for 

2a_txt_OpportunityAmount cant be blank.
IF 2a_txt_OpportunityAmount is answered "yes"

2b_txt_OpportunityAmount must be filled in also

 

Further consider changing to a Switch statement

 

Hope this helps

 

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

365 EduCon 768x460.png

Microsoft 365 EduCon

Join us for two optional days of workshops and a 3-day conference, you can choose from over 130 sessions in multiple tracks and 25 workshops.

Users online (4,117)