I'm a fairly new user to Power Apps and I have a struggle I need help with. Here is what I have:
The attached pic is for an expense report. There are three sections: Top is the header, which goes to the header table in SQL. Middle is for inserting a new line in the detail table in SQL. The bottom one is the gallery of what has been input as a line item into the detail table in SQL.
Here is what I'm trying to do:
I want the user to be able to enter the header table data for that information and save it to the header table. Then I'd like that portion of the screen to keep that data on the screen and just go to FormMode.View. At the same time, I'd like the HKey field in the middle portion of the screen to get the PKey field from the header and hold it there for all line item entries so that I can have a link from the header to the lines.
My struggle is getting the PKey field to the HKey field. What is the best way to accomplish this? I've tried global variables and context variables with no success. I'm certainly missing something, but can't figure out what! Please help!