DavidBurns1
2 years agoQrew Member
Formula referencing a Text - Multi-line connected from another App
Hi, this is my first time on the community, so I'm hoping I'm doing this right. I have a problem I'm trying to solve with a record that is created via a Pipeline looking for changes in another app. Here's the structure:
Two apps: App A and App B. App A has a field (Text - Multi-line) called [Highlight]. When a record in App A is updated and the field [Highlight] is changed, the Pipeline create a new record in App B and populates the value in [Highlight] of App A in a field (Text - Multi-line) called [Reported Highlight] in App B. This seems to be OK and looks good when you view it in a form or report. However, here's where the problem starts to arise. I have a Formula - Text field called [Reported Highlight Formatted] that adds a leading "- " to the [Reported Highlight], and searches and replaces a "\n" with a "\n - ". This should create a bulleted list for multi-line values that have multiple carriage returns.
Here is the formula for [Reported Highlight Formatted]:
"- " & SearchAndReplace([Reported Highlight],"\n","\n- ")
Using the REST API, here are the "value" results of the [Reported Highlight] and [Reported Highlight Formula] after the Pipeline runs and creates the new record.
[Reported Highlight]
"data": [{"6": {"value": "11.\n11."}}
[Reported Highlight Formatted]
"data": [{"27": {"value": "- 11.\n11."}}
Note that the leading "- " was added as defined in the formula, but the "\n" was not replaced with a "\n - " prior to the second 11.
This is where things get a little weird. When I open up the record, and do nothing more than Save and Close the record, the following are the results of the two fields.
[Reported Highlight]
"data": [{"6": {"value": "11.\r\n11."}}
[Reported Highlight Formatted]
"data": [{"27": {"value": "- 11.\r\n- 11."}}
As you can see, following a Save and Close with no changes whatsoever, a change is made to [Reported Highlight] and now the formula works for the [Reported Highlight Formatted]. Obviously, I'm not interested in opening and saving each record when they are created to get the formula to work. What do I need to do differently to make this work given the original output from the Pipeline created record?
Thanks in advance for your help!
David Burns
AbbVie
------------------------------
David Burns
------------------------------
Two apps: App A and App B. App A has a field (Text - Multi-line) called [Highlight]. When a record in App A is updated and the field [Highlight] is changed, the Pipeline create a new record in App B and populates the value in [Highlight] of App A in a field (Text - Multi-line) called [Reported Highlight] in App B. This seems to be OK and looks good when you view it in a form or report. However, here's where the problem starts to arise. I have a Formula - Text field called [Reported Highlight Formatted] that adds a leading "- " to the [Reported Highlight], and searches and replaces a "\n" with a "\n - ". This should create a bulleted list for multi-line values that have multiple carriage returns.
Here is the formula for [Reported Highlight Formatted]:
"- " & SearchAndReplace([Reported Highlight],"\n","\n- ")
Using the REST API, here are the "value" results of the [Reported Highlight] and [Reported Highlight Formula] after the Pipeline runs and creates the new record.
[Reported Highlight]
"data": [{"6": {"value": "11.\n11."}}
[Reported Highlight Formatted]
"data": [{"27": {"value": "- 11.\n11."}}
Note that the leading "- " was added as defined in the formula, but the "\n" was not replaced with a "\n - " prior to the second 11.
This is where things get a little weird. When I open up the record, and do nothing more than Save and Close the record, the following are the results of the two fields.
[Reported Highlight]
"data": [{"6": {"value": "11.\r\n11."}}
[Reported Highlight Formatted]
"data": [{"27": {"value": "- 11.\r\n- 11."}}
As you can see, following a Save and Close with no changes whatsoever, a change is made to [Reported Highlight] and now the formula works for the [Reported Highlight Formatted]. Obviously, I'm not interested in opening and saving each record when they are created to get the formula to work. What do I need to do differently to make this work given the original output from the Pipeline created record?
Thanks in advance for your help!
David Burns
AbbVie
------------------------------
David Burns
------------------------------