cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Post Partisan
Post Partisan

use Notify if conditions are false

I have a "Ask Question" button with the "OnSelect" code:

If((Topics_Input.Selected.Result = "<Select Drop Down>") ||
   (Subtopic_Input.Selected.Result ="<Select Drop Down>"),
    UpdateContext({visible:false}),UpdateContext({visible:true}))
//checking to see if both topic and subtopic have a value picked to make a "Submit Question" button visible.

 

What I need:

For either condition, when I click the "Ask Question"  button. for "onselect"

If they  have not chosen a value in either dropdown I need a  "Notify", stating that a value is needed ?

 

Dave

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Super User III
Super User III

Re: use Notify if conditions are false

Hi @DAVIDPOWELL ,

You can add this onto the end of the Visible

If(
   Topics_Input.Selected.Result = "<Select Drop Down>" ||
   Subtopic_Input.Selected.Result ="<Select Drop Down>",
   UpdateContext({visible:false});
   Notify(
      "You need to select both options in dropdowns",
      NotificationType.Error
   ),
   UpdateContext({visible:true})
)

 

Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

View solution in original post

4 REPLIES 4
Highlighted
Super User III
Super User III

Re: use Notify if conditions are false

@DAVIDPOWELL 

Didn't we resolve this one in the other post?  Or is this something different?

_____________________________________________________________________________________
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.
Highlighted
Super User III
Super User III

Re: use Notify if conditions are false

Hi @DAVIDPOWELL ,

You can add this onto the end of the Visible

If(
   Topics_Input.Selected.Result = "<Select Drop Down>" ||
   Subtopic_Input.Selected.Result ="<Select Drop Down>",
   UpdateContext({visible:false});
   Notify(
      "You need to select both options in dropdowns",
      NotificationType.Error
   ),
   UpdateContext({visible:true})
)

 

Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

View solution in original post

Highlighted
Post Partisan
Post Partisan

Re: use Notify if conditions are false

@RandyHayes,

I forgot I need some type of notify banner for visual purposes.

 

Dave

Highlighted
Super User III
Super User III

Re: use Notify if conditions are false

@DAVIDPOWELL 

Gotcha - then you can use the formula that @WarrenBelz has suggested.

Also consider that rather than displaying notices, you can place labels under your dropdowns that indicate the values are needed.  Then set their visible property based on the selection, or lack of selection, in the dropdown.

Just a little more "App-like".

_____________________________________________________________________________________
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
Community Conference

Power Platform Community Conference

Find your favorite faces from the community presenting at the Power Platform Community Conference!

Watch Now

Experience what’s next for Power Apps

See the latest Power Apps innovations, updates, and demos from the Microsoft Business Applications Launch Event.

Power Platform ISV Studio

Power Platform ISV Studio

ISV Studio is designed to become the go-to Power Platform destination for ISV’s to monitor & manage published applications.

secondImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Top Solution Authors
Top Kudoed Authors
Users online (7,824)