web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / PowerApps - Update Dyn...
Power Apps
Unanswered

PowerApps - Update Dynamics Table column based on DropDown Column Name Value

(0) ShareShare
ReportReport
Posted on by 89

Hi

I would like to be able to Update a specific column value in my Dynamics 364 table based on the Column name selected in a Drop Dowm menu. Based on the value selected from the drop down, it will select proper columns to action on the Patch.

 

This portion: scl_tscauditrequestid = GUID(txTscAuditRequestNumber.Text)  will search for the unique value.

 

Then, if i select a value in my Drop Down menu that equals a column name inside that table, Example: "slc_Comments:", when i will press on the button, it will put the value from txNewValue.Text into "slc_Comments" column of the row corresponding to unique value that equals

to GUID(txTscAuditRequestNumber.Text) 

 

 

 

 

Patch(
 'Audit dbase',
 LookUp(
 'Audit dbase',
 scl_tscauditrequestid = GUID(txTscAuditRequestNumber.Text)
 ),
 {
 cbDbColumnSelection.Select.Value = txNewValue.Text
 
 }
 )

 

 

 Above code does not work. But how can i do that?

 

Thanks for your help.

Categories:
I have the same question (0)
  • Verified answer
    v-xiaochen-msft Profile Picture
    on at

    Hi @Wilder1626 ,

     

    You cannot use a selected text value to refer to a column name.

    So, you could modify the formula like this:

    If(cbDbColumnSelection.Select.Value="slc_Comments",
    Patch(
     'Audit dbase',
     LookUp(
     'Audit dbase',
     scl_tscauditrequestid = GUID(txTscAuditRequestNumber.Text)
     ),
     {
     slc_Comments = txNewValue.Text
     
     }
     ),
    cbDbColumnSelection.Select.Value=Another column Name,
    Patch(
     'Audit dbase',
     LookUp(
     'Audit dbase',
     scl_tscauditrequestid = GUID(txTscAuditRequestNumber.Text)
     ),
     {
     Another column Name = txNewValue.Text
     
     }
     ))

     

    Best Regards,
    Wearsky
    If my post helps, then please consider Accept it as the solution to help others. Thanks.

  • Wilder1626 Profile Picture
    89 on at

    Thanks. This will work.

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 796 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 327 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard