I am extracting information from google sheet and using these info as dropdown. However, when I select the options and execute it, it comes with extra spaces and extra line break.
-
I have kept trim function but still extra spaces.

-
While executing snippet. If you see, there is space between word and comma, which is not required.

-
Output with extra space and line-break. Cursor is coming in next line.

I am not really sure whether this is because of google sheet urlload command or I am not doing trim properly. @Cedric_Debono_Blaze Thanks
Sometimes this happens with Snippets my teams and I use in Salesforce Lightning. The solution I implemented was to put a {key:backspace} command to get rid of the line break. Sometimes we need to get a little creative and combine it with an arrow key command or 2 to get it to work how it must in a particular field. Salesforce is notorious for fields behaving differently despite them looking the same on the surface.
Hope this idea helps spark a solution for you!
-Brad
2 Likes
Thanks Brad, that's really creative thinking. I never had a thought like that.
1 Like
Before your {endnote}
, can you add this:
{current_options_trimmed = map(current_options, x -> trim(x))}
Basically, this trims each item in the list manually. Then use current_options_trimmed
in your formmenu. Hopefully this will work.
3 Likes
Thank you Gaurang, that worked. One last thing, there is extra line-break before the sentence as well? how do I remove it? E.g. above Anxiety worsening....
Might be due to the snippet layout itself. Try putting the chips in the snippet consecutive to each other (next to each other on same line) or try putting trim=yes
in some of them that are near the line break.
2 Likes
Thanks. That's what I thought and it worked. Thank you for all your help.
2 Likes
You are welcome, glad I was able to help 
1 Like
This is really late, but I found that If I copy and paste what I want with ctrl + shift + v
It retains the formatting it had before without adding a space or extra lines.
Try fixing the issue with formatting in google sheet, and then copy pasting with shift into text blaze.