cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Anonymous
Not applicable

Help with passing context in navigate

Being a non-developer, I need help to get the following please.

 

Basic CRM-type App: One "Customer" can have multiple "Contacts". In the Customer screen there is a button to add a new contact for that Customer. So the context variable that I need to pass onto the new Contact Form is the Customer Name. I seem to be doing something wrong in my reference as I cannot get the new form to default to the Customer Name from the previous screen.

 

Kindly advise if you are able to detect the error from the attached screenshots.

(hypethetical data used)

 

1: The formula used OnSelect for the button in question

 

screen1.PNG

 

 

2. The value of the record that I am trying to pass on to the next screen

 

screen2.PNG

 

 

3. The place where I am trying the value to end up which is not working.

 

screen3.png

 

 

2 REPLIES 2
Community Support Team
Community Support Team

Re: Help with passing context in navigate

Hi @Anonymous,

 

NewForm() places the form in "New" mode thereby causing the form to pick default values. Default values are what are configured on the datasource directly not through PowerApps.

 

Regards,

Mona

Community Support Team _ Mona Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Anonymous
Not applicable

Re: Help with passing context in navigate

Please offer alternative solution for the objective. The goal is merely to create a "sub-record", i.e. Attach a Contact Person to the Company Header record. That should be possible. 

 

I got somehat further, but issue is not fully resolved.  Using the below OnSelect formula it now populates the customer in the next screen. However it seems that this is not recognised within the app since I get the below error when I try to submit the formThe only way around it seems to create a duplicate field and manually choose from the dropdown exactly the same value. Perhaps its something to do with the ID not being updated when the default value is set.

 

There must be a better way. I would appreciate your assistance. 

 

CaptureA1.PNGCaptureA2.PNG

Helpful resources

Announcements
thirdimage

Power Apps Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Power Platform World Tour

Find out where you can attend!

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

SecondImage

Difinity Conference

The largest Power BI, Power Platform, and Data conference in New Zealand

Top Solution Authors
Top Kudoed Authors (Last 30 Days)
Users online (4,890)