Posting code snippets to Microsoft Teams

image

If you want to post a snippet of code to Microsoft Teams go to the Conversations tab and then select the Format text icon as shown above.

image

From this expanded dialog box select the Code icon as shown.

image

This should display a new dialog like shown above.

image

If you select the options in the top right you will see a huge range of code selections displayed as shown.

image

In the above case, I have select PowerShell and you can see that it formats and colours the code snippet for me automatically making it much easier to read.

image

You can now post the result and that will be added to the Teams Conversations as shown above. You will see that it even automatically add line numbers, which is very handy.

Thus, if you are going to post code into Microsoft Teams Conversations, make sure you do it via the Format Text option so that it is formatted in a way that makes it more readable.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s