Skip to main content
Community site session details

Community site session details

Session Id : FvdVpZDu2h4mjVHPH+g5Kg
Power Apps - Error Handling
Answered

Seperate to functions with comma or semicolon

Like (0) ShareShare
ReportReport
Posted on 24 Jun 2025 07:06:32 by 21
Hello everyone.

i´ve the following code at a button - OnSelect 

The problem is that neither semicolons nor commas work to separate the functions.
 
Patch(
    UserHierarchy;
    galUsers.Selected;
    {
        ManagerID: {
            Id: cmbMgr.Selected.ID;
            Value: cmbMgr.Selected.FullName
        }
    }
);
Refresh(UserHierarchy);
ResetForm(Form1);
EditForm(Form1)
 

If I use the semicolon, I get the following error message for the semicolon between the patch and refresh function:
Unexpected characters. Characters are not used as expected in the formula.






 
Patch(
  UserHierarchy,
  galUsers.Selected,
  {
    ManagerID: {
      Id: cmbMgr.Selected.ID,
      Value: cmbMgr.Selected.FullName
    }
  }
);
Refresh(UserHierarchy);
ResetForm(Form1);
EditForm(Form1)
 
If I use the comma as a separator for the functions, 
I get the following error message:
Unexpected characters. The formula contains ‘Error’, but ‘ParenClose’ is expected.
Unexpected characters. Characters are not used as expected in the formula.

 
For your information.
The problem is not unique to this code.
Whenever I have two functions in a code and I have to separate them, I get the error
 

I have set German as the language in the app. But even if I set the language to English, the errors still occur.
I just can't find a solution

Thanks for help

Marcus
  • Verified answer
    StretchFredrik Profile Picture
    3,099 Super User 2025 Season 2 on 24 Jun 2025 at 07:23:00
    Seperate to functions with comma or semicolon
    See if the code below works. 
    Patch(
        UserHierarchy;
        galUsers.Selected;
        {
            ManagerID: {
                Id: cmbMgr.Selected.ID;
                Value: cmbMgr.Selected.FullName
            }
        }
    );;
    Refresh(UserHierarchy);;
    ResetForm(Form1);;
    EditForm(Form1)
    If my response solved your issue, please mark it as ✅ Accepted Answer and give it a like.
     

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

Telen Wang – Community Spotlight

We are honored to recognize Telen Wang as our August 2025 Community…

Announcing our 2025 Season 2 Super Users!

A new season of Super Users has arrived, and we are so grateful for…

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 637 Most Valuable Professional

#2
stampcoin Profile Picture

stampcoin 570 Super User 2025 Season 2

#3
Power Apps 1919 Profile Picture

Power Apps 1919 473

Featured topics

Loading complete