Good day all!
I have an app that creates a ticket and has various stages where different parties have to fill in their part. One part asks the I.T. group to fill in how much the request is going to cost. If this is a new ticket, I would like that box to start out blank. If they have already filled in the number and saved it, I (of course) would like it to display the number that is now stored in the SharePoint.
The problem I am having, is that when someone views another ticket, and that variable is picked up, that number stays in the buffer and is then displayed in the next ticket if there was a blank. If they open a ticket where a different number is, then the new number is displayed. So, this problem only happens if the second ticket was supposed to be blank in that box.
The current code in my 'default':
can anyone please help me?
thank you!
David
Solved! Go to Solution.
Hi @davyjones ,
Please consider changing the value of the variable to blank after you are done using it. For instance to add the below formula to the OnSucces property of a form where the variable is used to populate one of the fields in the form:
Set(Variable,Blank())
Hi @davyjones ,
Please consider changing the value of the variable to blank after you are done using it. For instance to add the below formula to the OnSucces property of a form where the variable is used to populate one of the fields in the form:
Set(Variable,Blank())
good morning, @BCBuizer !
I set that bit of code not only on the 'onselect' of the save button (after the patching), but also on the 'onsuccess' of the form on that page. The problem still remains. Anything that is saved from that variable remains when someone opens a different ticket. do you know what I might be doing wrong?
thank you,
david
Hi @davyjones ,
Assuming the variable is blank as expected, the default value may come from Parent.Default. Can you share the Default property of the DataCard and the Item property of the form?
hey @BCBuizer , thank you for getting back. As requested, here are the results:
This seems right, as it is calling the value from the SharePoint for that particular field.
I am guessing that you are speaking of the form within that particular screen, right? this is that, and doesnt look too bad. I am at a loss here!
Hi @davyjones ,
I assume _RequestForm is some kind of variable. Can you make sure this is updated when the user selects a different ticket?
Hey @BCBuizer ! sorry for taking so long to reply, work got very busy!
Yes, the idea is that after the user hits the 'save' button on the previous ticket, the variable would then clear out, so it wouldnt be on any other tickets. I have that code on the 'save' button shown below. However, I tried again this morning and it seems to save the variable even though everything looks clean. Thoughts?
Also, here is the code for the box itself, maybe there is something that can be improved here?
User | Count |
---|---|
252 | |
126 | |
104 | |
50 | |
49 |