Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Power Apps - Power Apps Pro Dev & ISV
Unanswered

Create record and show newly created record

(0) ShareShare
ReportReport
Posted on by 79

Hi folks,

 

we have a PowerApp in development which shows records from the Dataverse in a gallery view.

By clicking on a record entry, a page ("General") opens, where some fields are available to edit the record, existing data is loaded into these fields.

We also have a functionality in our app to create whole new records. This functionality links the same "General" page where the same fields are available, but empty.

By clicking on the save button on the "General" page, a patch function runs to create the record in the Dataverse.

So far, so good. 

We want to keep the page opened after the patch with the data from the newly created record shown (so technically close the "create page" and open the "edit page" with data from the new record).

But currently all data will be removed from the fields after the patch, so the page is shown in "create form" again.

 

Any advice on how to achieve this?

 

We already tried several things, which worked also out in the editing mode, but after publishing the app, a lot of error messages were thrown...

 

Open the Create page:

 

Create_Button.OnSelect = Set(selectedRecord; Defaults('Meeting Minutes'));;
Navigate(General);;
General_Form_BasicFields.Items = selectedRecord

 

 

Function on the Save button:

 

Save_Button.OnSelect =

If(
IsBlank(Validate('Meeting Minutes'; selectedRecord; General_Form_BasicFields.Updates; General_Form_Description.Updates; General_Form_Subject.Updates ));

//true

Set(selectedRecord; Patch('Meeting Minutes'; selectedRecord; General_Form_BasicFields.Updates; General_Form_Description.Updates; General_Form_Subject.Updates);;
EditForm(General_Form_BasicFields);;EditForm(General_Form_Description);;
EditForm(General_Form_Subject);;

Notify("Your Meeting Minutes was created successfully.";
NotificationType.Success
);

//false
Notify(
First(Errors('Meeting Minutes')).Message;
);;

)

 

 

Any advice is appreciated! 

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

Announcing the Engage with the Community forum!

This forum is your space to connect, share, and grow!

🌸 Community Spring Festival 2025 Challenge Winners! 🌸

Congratulations to all our community participants!

Warren Belz – Community Spotlight

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

Leaderboard > Power Apps - Power Apps Pro Dev & ISV

#1
WarrenBelz Profile Picture

WarrenBelz 109 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 82 Super User 2025 Season 1

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 72

Overall leaderboard