cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
rthompsoneu
Frequent Visitor

Using Dynamic 365 - Issue with field that is a multiple lines of Text that contain newline break

Hi,

 

I have an entity that I use to get instruction information.  I want to get a field from that entity and store it on a approval.

 

The field contain newline break.   I tried using using json.   My result in my e-mail are coming out blank.

 

 

Output.JPG

 

The first compose contains :   body('Get_record')?['new_instruction']

 

The compose 2 contains :  json('{"Compose":"\r\n"}')?['new_instruction']

 

Instructions.JPG

 

My results look like this

 

Output2.JPG

1 ACCEPTED SOLUTION

Accepted Solutions
v-litu-msft
Community Support
Community Support

Hi @rthompsoneu,

 

Please have a try this expression to get the value of new_instruction:

body('Get_record')?['value'][0]['new_instruction']

 

Best Regards,
Community Support Team _ Lin Tu
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
v-litu-msft
Community Support
Community Support

Hi @rthompsoneu,

 

Please have a try this expression to get the value of new_instruction:

body('Get_record')?['value'][0]['new_instruction']

 

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

Thanks  _ Lin Tu

 

That fixed my issue.

 

Still trying to understand the expression 

body('Get_record')?['value'][0]['new_instruction']

 

 

Hi @rthompsoneu,

 

The value is an array, the new_instruction is contained in the member of value, so if you want to get the new_instruction, you should get the array of the value firstly, then get the first member of the value array by using the index '0'. 

Then use the property name new_instruction to get its value back.

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

Helpful resources

Announcements
Microsoft 365 Conference – December 6-8, 2022

Microsoft 365 Conference – December 6-8, 2022

Join us in Las Vegas to experience community, incredible learning opportunities, and connections that will help grow skills, know-how, and more.

Users online (5,213)