cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
techtudoor
Resolver I
Resolver I

SharePoint ID not populating in ticket number field

I am building a PowerApp for a ticketing system. My main landing screen is similar to a EULA screen where users attest to the terms and conditions.

 

I have set my PowerApp to submit the Yes I agree field (via checkbox) to a SharePoint List on a button click. Then my app goes to the next screen where users input their requests. The second screen has a  Request Number field ("REQ" &Year(Now()) &"-" &ThisItem.ID).

 

I have the form on the second screen Item property set to (Form1.LastSubmit). I can see the SharePoint ID in the list, but the field on the second screens form does not show the ID. How can I get the request field to pull the SharePoint ID when it loads?

 

It would be very beneficial to show the Request number so the user can see the request number. 

 

Suggestions greatly appreciated. 🙂

1 ACCEPTED SOLUTION

Accepted Solutions
v-xida-msft
Community Support
Community Support

Hi @techtudoor , 

Is there a Edit form (Form1) existed in your first screen to save the Yes I agree field value (via checkbox) to a SharePoint List?

Have you reset your Form1 after you submit your Form1 data?

 

Based on the issue that you mentioned, I think this issue may be related to the Form1.LastSubmit formula you typed within the Item property of the second Edit form.

 

I have made a test on my side, please consider take a try with the following workaround:

Set the OnSuccess property of the Form1 to following:

Set(SubmittedRecord, Form1.LastSubmit);   // Add this formula
Navigate(SecondScreen)

Within the second screen, set the Item property of the Edit form to following:

SubmittedRecord

then try the following formula within the Default property of the Request Number Text Box:

"REQ" &Year(Now()) & "-" & ThisItem.ID

or

"REQ" &Year(Now()) & "-" & SubmittedRecord.ID

 

Please consider take a try with above solution, check if the issue is solved.

 

Best regards,

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

3 REPLIES 3
WarrenBelz
Super User III
Super User III

Hi @techtudoor ,

A bit unusual, I assume that 

("REQ" &Year(Now()) &"-" &ThisItem.ID)

is the Default of the field?

This may not work, but try at Screen OnVisible

Reset(YourRequestNumberControl)

 

Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

v-xida-msft
Community Support
Community Support

Hi @techtudoor , 

Is there a Edit form (Form1) existed in your first screen to save the Yes I agree field value (via checkbox) to a SharePoint List?

Have you reset your Form1 after you submit your Form1 data?

 

Based on the issue that you mentioned, I think this issue may be related to the Form1.LastSubmit formula you typed within the Item property of the second Edit form.

 

I have made a test on my side, please consider take a try with the following workaround:

Set the OnSuccess property of the Form1 to following:

Set(SubmittedRecord, Form1.LastSubmit);   // Add this formula
Navigate(SecondScreen)

Within the second screen, set the Item property of the Edit form to following:

SubmittedRecord

then try the following formula within the Default property of the Request Number Text Box:

"REQ" &Year(Now()) & "-" & ThisItem.ID

or

"REQ" &Year(Now()) & "-" & SubmittedRecord.ID

 

Please consider take a try with above solution, check if the issue is solved.

 

Best regards,

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

@v-xida-msft , using SubmittedRecord.ID worked great.

 

Thank you

Helpful resources

Announcements
PA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

Power Query PA Forum 768x460.png

Check it out!

Did you know that you can visit the Power Query Forum in Power BI and now Power Apps

V3_PVA CAmpaign Carousel.png

Community Challenge - Giveaways!

Participate in the Power Virtual Agents Community Challenge

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

Top Solution Authors
Top Kudoed Authors
Users online (2,291)