Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Power Apps - Building Power Apps
Answered

Changes in unrelated fields deletes text field when editing form

(0) ShareShare
ReportReport
Posted on by

I have a form with several fields. One is a description field and another one is a button controlled variable selection. There are four buttons that toggles the value for a datacard (button 1 = southwest, button 2 = northwest and so on). When I use the form in edit mode for existing objects, something weird is happening. If I change the variables using the buttons, the field where the variable is suppose to go is unchanged, but a second field which is populated from said field is updated. Also, the description is deleted, unless I also add a change to the description (any change will do).

 

My OnSelect in the Gallery view of the form is

Set(varMode;"Edit");; Navigate([@graveskjema_rediger];ScreenTransition.UnCover)

 

My OnSuccess for the form is 

Set(CurrentSubmittedRecord; graveskjema_rediger_form.LastSubmit);; NewForm(graveskjema_rediger_form)

 

My OnSelect that submits the form is

If(varMode = "Edit"; SubmitForm(graveskjema_rediger_form);;Navigate(graveskjema_vis); SubmitForm(graveskjema_rediger_form))

 

I have no idea where to start my debugging on this problem as the app is starting to get more and more complex. Any suggestions?Note ID 2 before editingNote ID 2 before editingForm with ID 2 in Edit mode, changed the number 55 to 66 and the button SØ to SVForm with ID 2 in Edit mode, changed the number 55 to 66 and the button SØ to SVNote ID 2, no change to KvadrantNote ID 2, no change to KvadrantID 2 in edit mode again, description is gone and Valgt rute has been updated to SVID 2 in edit mode again, description is gone and Valgt rute has been updated to SV

  • Verified answer
    CU12090750-0 Profile Picture
    on at
    Re: Changes in unrelated fields deletes text field when editing form

    So the solution to my problem was simple; I had the column setting for the description set to add changes to existing text, leading to multiple lines of formatted text, which the powerapps form could not read. 

     

    I also solved the Kvadrant variable issue by moving the variable out of the form and set it as a global variable, with some reset function on the forms on start if in edit mode, to avoid the impression that the button selected was in fact the selected button. Also , I couldn't get my head around how to set the global variable based on the current selected item if in edit mode...

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

🌸 Community Spring Festival 2025 Challenge 🌸

WIN Power Platform Community Conference 2025 tickets!

Markus Franz – Community Spotlight

We are honored to recognize Markus Franz as our April 2025 Community…

Kudos to the March Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 146,645 Most Valuable Professional

#2
RandyHayes Profile Picture

RandyHayes 76,287 Super User 2024 Season 1

#3
Pstork1 Profile Picture

Pstork1 65,997 Most Valuable Professional

Leaderboard