How To maintain an existing value in a field that is updated by a quick action with a prompt function
To maintain an existing value in a field that is updated by a quick action with a prompt function you can do the following:
For 2014.1.1 You will not be able to display the default text in the prompt function:
In the quick action, set the resolution field as follows:
Set incident resolution to $(Resolution + "\r\n" + Prompt("Resolution Notes", "", 400,200))
Where Prompt function Syntax is as follows:
prompt(string, validationList, w, h)
string: Contains the message that shows during the prompt.
validationList: Either empty or the name of the validation list used to provide values for the user to select.
w: The width of the text area in pixels.
h: The height of the text area in pixels.
The "\r\n" adds a new line to the text so that the text entered in the prompt starts on a new line.
Although you do not see the existing resolution notes in the prompt window, they will be maintained and the results of the prompt will be added onto a new line.
2014.2.1 allows you to add a default value to the prompt and you would use the resolution field for that.
$(Prompt("Resolution Details", "", 400, 200, false, false, Resolution))
This was extrapolated from the online help information for the prompt function. All the above string is saying is:
prompt(message, promptData, fieldAreaWidth, fieldAreaHeight, password, required, defaultValue)
1. Prompt for "Resolution Details"
2. Do not use a pick list ""
3. The window height should be 400 pixels
4. The window width should be 200 pixels
5. Do not show a password mask
6. Do not make the field required
7. Use the Resolution field as the default value.
version 2014.2.1 allows you to include the previous text in the prompt using the default value. If you do not wish to present the previous text in the prompt itself, just use the function as presented for 2014.1.1