Bot - How to return a new line from the bot to both skype preview and skype web application

I have a bot application that returns a new line only for the Skype 10 preview window using \ n \ n. However, when I display the message in the https://web.skype.com/en/?ecsoverride=developer web application, it does not respect newline breaks and presents it as the current line.

I do not see this help: https://docs.botframework.com/en-us/csharp/builder/sdkreference/activities.html ... how to present a new line no matter what the client will be - is there a new line, which can be used for any client who receives a message from my bot? If I add something like this, it will display like this text in my windows 10 application as skype instead of a new line - I am looking for a new line that works on any client.

Any ideas?

+5
source share
5 answers

Update for version 3.5 Paging on line \n\n creates a new paragraph. As below:

"Paragraph1_text/n/nParagraph2_text" results in

 Paragraph1_text Paragraph2_text 

Old versions

I found that placing two spaces + the NewLine character solves the problem (C # code):

 return $"some text: {Environment.NewLine}text from new paragraph" 

or

 return $"some text: \ntext from new paragraph" 

Result

 some text: text from new paragraph 

This works for both the Microsoft Bot Framework emulator and Skype chat.

+7
source

HTML line break insertion <br/> works!

+5
source

I use two new lines with the character "un-joiner" without width . => \n\n\u200C
I successfully tested it on Facebook, Skype, Webchat, Emulator.

It also works if you want blank lines!

+3
source

The combination \n\u200C<br> works.

0
source

Send multi-line responses or send multiple answers so they look multi-layered

https://github.com/Microsoft/BotBuilder/issues/33

-1
source

All Articles