Skip to main content

Notifications

Community site session details

Community site session details

Session Id : NWIGx+jy18bWaj4Vgbj0vZ
Power Apps - Building Power Apps
Answered

How to Stop OnChange event of Dropdown List

Like (0) ShareShare
ReportReport
Posted on 27 Jun 2022 05:49:22 by 34

 

Hi,

I am using the Dropdown list. While Inserting the Record in the sharepoint list(Personal Info form) ,OnChange event of Drop Down list(depends on Text) I am navigating to another form(Experience Details) Where I am Inserting Information and Coming Back to Personal Info Form). Which is working fine.

But when I am editing the form When I have to Navigated to Personal Info Form  I will directly Navigating to Experience Details form.

I think this is happened due to OnChange of the DropDown List.

How to Stop it.

 

This is the Code onChange of DropDown

 varEditMode is variable which will decide Its New Entry of Edit the Entry

If((varEditMode="0") And ((cmbLastWorking.Selected.Value="Currently") Or (cmbLastWorking.Selected.Value="Last Working")),
Navigate(scrExperienceDetails));

If((varEditMode="1") And ((cmbLastWorking.Selected.Value="Currently") Or (cmbLastWorking.Selected.Value="Last Working")),
Navigate(scrExperienceDetails));

DropDown Problem.jpg

  • Verified answer
    WarrenBelz Profile Picture
    146,776 Most Valuable Professional on 27 Jun 2022 at 07:13:41
    Re: How to Stop OnChange event of Dropdown List

    Hi @dipakbadgujar ,

    Yes, that is one of the quirks (some would say bugs) of Combo Boxes OnChange event firing when a Form is opened. There are a couple of strategies. If for instance you opened the form in View Mode and (obviously) only wanted to fire the event in Edit Mode, you could make the OnChange conditional on being in Edit mode (so it would not fire when the form is opened). Another one (which I have used once) is to make the OnChange also conditional on a Variable being true. Use a Global variable and set it to false before you enter the screen and then have a hidden timer (2-3 seconds will do) setting it to true OnTimerEnd.

     

    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.

    Visit my blog Practical Power Apps

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Understanding Microsoft Agents - Introductory Session

Confused about how agents work across the Microsoft ecosystem? Register today!

Warren Belz – Community Spotlight

We are honored to recognize Warren Belz as our May 2025 Community…

Congratulations to the April Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 146,776 Most Valuable Professional

#2
RandyHayes Profile Picture

RandyHayes 76,287 Super User 2024 Season 1

#3
Pstork1 Profile Picture

Pstork1 66,093 Most Valuable Professional

Leaderboard
Loading started