Hello,
I have a source SharePoint list called "NCC List".
In my app I have a screen called "Screen_NCC" with:
1. gallery called "Gallery_Requests"
2. form called "Form"
The Form shows item selected from gallery, but "Gallery_Requests.Selected" did not work for some reason, so I have in item property of my form following formula: "LookUp('NCC List',ID=Gallery_Requests.Selected.ID)"
In my form, I need to set format of my Text Input field "DataCardValue37" so it shows "20.000" instead of "20000" - so I only need to separate thousands with dots during form editing.
In order to achieve this I did following:
1. DataCardValue37 - On Change property:
Set(FormattedNum,Text(Value(DataCardValue37.Text),"[$-en-US]#,###"));Reset(DataCardValue37)
2. DataCardValue37 - Default property: FormattedNum
3. Screen_NCC - On Visible property:
If(Form.Mode=FormMode.New,Set(FormattedNum,""),Set(FormattedNum,DataCardValue37.Text))
What happens when I preview the app. The field is formatted immediately after I input the value and click in another field. That is perfect.
When I click on Save button (On select property shows: SubmitForm(Form)), it saves the entry.
But when I click on New button (On select property set as follows: ResetForm(Form); NewForm(Form)), the value that I entered previously remains in DataCardValue37. It is not empty, but I would like to have a clear form when clicking on New button.
Form default mode is view as it is meant to show item selected from gallery. However users have the option to edit item with Edit button (On select property: EditForm(Form)), from there reset form back to view mode with Reset button (On select property: ResetForm(Form)) or create a new item by clicking on New button (On select property set as follows: ResetForm(Form); NewForm(Form)) - and afterwards of course save changes by submitting form.
Could you please advise how to achieve that the field will be empty when opening the new form?
Thank you very much in advance.
Kind regards,
Hana

Report
All responses (
Answers (