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

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Creating a field value...
Power Apps
Unanswered

Creating a field value based on other fields in a form (Model driven app)

(0) ShareShare
ReportReport
Posted on by 16

Hi, i have created an form where i have the primary name field and 3 lookup fields to othertables: Contract (not null), Product (not null), subproduct(null)

 

I want the primary name field to be created based on the chosen lookup fields - so it becomes sort of a unique field. can anyone help me on how to accomplish this in a model driven app ?  if the answer is Javascript i might need help to write it.

 

Categories:
I have the same question (0)
  • Nogueira1306 Profile Picture
    7,390 Super User 2024 Season 1 on at

    Set the Default of that field to the 3 LookUps you make.


    EXAMPLE:
    LookUp(Contract; ID = 1) & "-" & LookUp(Product; ID = 1) & "-" & LookUp(SubProduct; ID = 1)

     

    If you need additional help please tag me in your reply and please like my reply.
    If my reply provided you with a solution, pleased mark it as a solution ✔️!

    Best regards,
    Gonçalo Nogueira

    Check my LinkedIn!

    Check my User Group (pt-PT)!

    Last Post on Community

    My website!

  • GreenPowerBI Profile Picture
    16 on at

    Thank you for the reply @Nogueira1306 .

     

    This would also be my solution if i was working on a canvas app, did not think it would work in a model driven app. where is it possible to write Power fx for default values in model driven apps? 

  • GreenPowerBI Profile Picture
    16 on at

    UPDATE. 

     

    i managed through workflow to set conditions (see pictures)

    CamFi_0-1639993474326.png

    CamFi_1-1639993496601.png

     

    But when i create a record, it only insert Contract and not Product or subproduct. does anyone know what i am doing wrong ? 

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the March Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 541

#2
WarrenBelz Profile Picture

WarrenBelz 434 Most Valuable Professional

#3
Valantis Profile Picture

Valantis 289

Last 30 days Overall leaderboard