SOLVED

Code Formatting

%3CLINGO-SUB%20id%3D%22lingo-sub-28748%22%20slang%3D%22en-US%22%3ECode%20Formatting%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-28748%22%20slang%3D%22en-US%22%3E%3CDIV%20class%3D%22message-replies%22%3E%3CDIV%20class%3D%22message-reply%20%22%3E%3CDIV%20class%3D%22reply-body%22%3E%3CDIV%20class%3D%22reply-text%22%3E%3CP%3EMy%20developers%20miss%20the%20ability%20to%20format%20their%20pasted%20code%20like%20they%20used%20to%20in%20HipChat.%20Any%20plans%20on%20adding%20this%20soon%3F%3C%2FP%3E%3C%2FDIV%3E%3C%2FDIV%3E%3C%2FDIV%3E%3C%2FDIV%3E%3CDIV%20class%3D%22message-add-reply%22%3E%26nbsp%3B%3C%2FDIV%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-28748%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3EMicrosoft%20Teams%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-338753%22%20slang%3D%22en-US%22%3ERe%3A%20Code%20Formatting%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-338753%22%20slang%3D%22en-US%22%3E%3CP%3ESame.%26nbsp%3B%20It%20just%20makes%20a%20gray%20box%20without%20any%20highlighting.%3CBR%20%2F%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20style%3D%22width%3A%20372px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F74932iE2144411EEBA887D%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20alt%3D%22nohighlighting.PNG%22%20title%3D%22nohighlighting.PNG%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-338339%22%20slang%3D%22en-US%22%3ERe%3A%20Code%20Formatting%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-338339%22%20slang%3D%22en-US%22%3E%3CP%3EI'm%20having%20the%20same%20problem.%20I%20believe%20this%20is%20the%20cause%3A%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Fmicrosoftteams.uservoice.com%2Fforums%2F555103-public%2Fsuggestions%2F36491929-code-markdown-fails-if-backtick-is-normal-non-d%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%22%3Ehttps%3A%2F%2Fmicrosoftteams.uservoice.com%2Fforums%2F555103-public%2Fsuggestions%2F36491929-code-markdown-fails-if-backtick-is-normal-non-d%3C%2FA%3E%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-252397%22%20slang%3D%22en-US%22%3ERe%3A%20Code%20Formatting%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-252397%22%20slang%3D%22en-US%22%3EMake%20sure%20to%20use%20the%20backtick%20%60%20and%20not%20the%20single%20quote%2Fapostrophe%20'%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-201290%22%20slang%3D%22en-US%22%3ERe%3A%20Code%20Formatting%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-201290%22%20slang%3D%22en-US%22%3E%3CP%3ECode%20formatting%20does%20not%20work%20when%20I%20use%20markdown.%20I%20tried%20Firefox%2C%20Chrome%2C%20Windows%20EXE%2C%20Android%20App%2C%20still%20no%20success.%20It%20makes%20my%20wonder%20that%20the%20MS%20support%20page%20(%3CA%20title%3D%22MS%20Support%20page%22%20href%3D%22https%3A%2F%2Fsupport.office.com%2Fen-us%2Farticle%2Fuse-markdown-formatting-in-teams-4d10bd65-55e2-4b2d-a1f3-2bebdcd2c772%22%20target%3D%22_self%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%22%3Ehttps%3A%2F%2Fsupport.office.com%2Fen-us%2Farticle%2Fuse-markdown-formatting-in-teams-4d10bd65-55e2-4b2d-a1f3-2bebdcd2c77%3C%2FA%3E%20)does%20show%20a%20working%20example%3A%3C%2FP%3E%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F35480i3D7C248FBFC8E1F3%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20alt%3D%22Capture.JPG%22%20title%3D%22Capture.JPG%22%20%2F%3E%3C%2FSPAN%3EAny%20hints%3F%20-%20Thanks%20Markus%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-127185%22%20slang%3D%22en-US%22%3ERe%3A%20Code%20Formatting%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-127185%22%20slang%3D%22en-US%22%3E%3CP%3EAlthough%20there%20is%20a%20way%20to%20paste%20pre-formatted%20code%2C%20it%20would%20be%20nice%20if%20this%20feature%20actually%20supported%20syntax%20highlighting%20like%20slack%20%2F%20hipchat.%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-125194%22%20slang%3D%22en-US%22%3ERe%3A%20Code%20Formatting%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-125194%22%20slang%3D%22en-US%22%3E%3CP%3EGiven%20that%20paste%20strips%20out%20linefeeds%2C%20this%20is%20of%20very%20limited%20use.%20I%20don't%20tend%20to%20retype%20code%20from%20scratch%20%3A(%3C%2Fimg%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-122536%22%20slang%3D%22en-US%22%3ERe%3A%20RE%3A%20Code%20Formatting%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-122536%22%20slang%3D%22en-US%22%3E%3CP%3EHello%2C%20any%20idea%20when%20this%20is%20going%20to%20be%20added%3F%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-92500%22%20slang%3D%22en-US%22%3ERe%3A%20Code%20Formatting%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-92500%22%20slang%3D%22en-US%22%3E%3CBLOCKQUOTE%3E%3CHR%20%2F%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F222%22%20target%3D%22_blank%22%3E%40Wictor%20Wilen%3C%2FA%3E%20wrote%3A%3CBR%20%2F%3E%3CP%3EThis%20feature%20is%20now%20available.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CHR%20%2F%3E%3C%2FBLOCKQUOTE%3E%3CP%3EAny%20way%20to%20switch%20it%20off%3F%26nbsp%3BAlso%2C%20any%20way%20to%20switch%20off%20%22Smart%20paste%22%2C%20wherein%20Teams%20tries%20to%20format%20stuff%20I've%20copied%20from%20elsewhere%20and%20into%20a%20Teams%20message.%20I%20do%20not%20-%20and%20never%20will%20-%20want%20the%20format%20copied%20between%20apps.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EI'm%20fine%20with%20it%20having%20formatting%20shortcuts%2C%20but%20I%26nbsp%3Bwant%20it%20to%20be%20an%20*active*%20choice%20on%20my%20part%3B%20I%20don't%20want%20Teams%20trying%20to%20be%20%22helpful%22%20and%20doing%20it%20for%20me.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%2Fme%20remembers%20Clippy...%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3ECheers.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E--%26nbsp%3B%3C%2FP%3E%3CP%3EAdam%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-92253%22%20slang%3D%22en-US%22%3ERe%3A%20Code%20Formatting%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-92253%22%20slang%3D%22en-US%22%3E%3CP%3EIf%20you%20paste%20in%20the%20text%20of%20the%20code%20into%20the%20message%20box%20and%20then%20click%20on%20the%20Expand%20compose%20box%20for%20formatting%20button%20on%20the%20bottom%20left%20(it%20looks%20like%20an%20A%20with%20a%20paintbrush)%20Then%20at%20the%20top%20of%20the%20compose%20box%20there%20will%20be%20a%20drop%20down%20list%20of%20Paragraph%20formatting%20options%2C%20choose%20Code.%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-55440%22%20slang%3D%22en-US%22%3ERe%3A%20Code%20Formatting%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-55440%22%20slang%3D%22en-US%22%3ECode%20formatting%20still%20not%20working%20here.%20Somebody%20mentioned%20it%20might%20be%20related%20to%20the%20language%20used%20for%20input%20(see%20%3CA%20href%3D%22https%3A%2F%2Fmicrosoftteams.uservoice.com%2Fforums%2F555103-public%2Fsuggestions%2F18532621-improved-markdown-support%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%22%3Ehttps%3A%2F%2Fmicrosoftteams.uservoice.com%2Fforums%2F555103-public%2Fsuggestions%2F18532621-improved-markdown-support%3C%2FA%3E%20).%20Is%20that%20a%20correct%20assumption%20and%20if%20so%20will%20it%20be%20fixed%3F%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-53339%22%20slang%3D%22en-US%22%3ERe%3A%20RE%3A%20Code%20Formatting%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-53339%22%20slang%3D%22en-US%22%3E%3CP%3EAny%20plan%20to%20handle%20syntax%20highlighting%3F%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-51419%22%20slang%3D%22en-US%22%3ERe%3A%20Code%20Formatting%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-51419%22%20slang%3D%22en-US%22%3ENot%20yet...%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-50847%22%20slang%3D%22en-US%22%3ERe%3A%20Code%20Formatting%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-50847%22%20slang%3D%22en-US%22%3E%3CP%3EThis%20is%20great%2C%20thanks%20for%20the%20update.%20%26nbsp%3BNow%20the%20next%20logical%20question%20--%20does%20it%20work%20on%20the%20mobile%20client%3F%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-50669%22%20slang%3D%22en-US%22%3ERe%3A%20Code%20Formatting%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-50669%22%20slang%3D%22en-US%22%3E%3CP%3EIt%20finally%20updated%20and%20YAY!%26nbsp%3B%20We%20have%20code%20formatting%20now.%26nbsp%3B%20Thanks%20so%20much%20for%20the%20great%20news%20Wictor!%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-50666%22%20slang%3D%22en-US%22%3ERe%3A%20Code%20Formatting%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-50666%22%20slang%3D%22en-US%22%3E%3CP%3EIt%20might%20be%20still%20rolling%20out%20to%20tenants%2C%20but%20here%20it%20is%20in%20action%3A%3C%2FP%3E%3CBLOCKQUOTE%3E%3CP%3EAnd%20here%20it%20is%3B%20Markdown%20in%20%3CA%20href%3D%22https%3A%2F%2Ftwitter.com%2Fhashtag%2FMicrosoftTeams%3Fsrc%3Dhash%22%20target%3D%22_blank%22%20rel%3D%22nofollow%20noopener%20noreferrer%20noopener%20noreferrer%22%3E%23MicrosoftTeams%3C%2FA%3E%3A%20%3CA%20href%3D%22https%3A%2F%2Ft.co%2F0BU8qW9f0S%22%20target%3D%22_blank%22%20rel%3D%22nofollow%20noopener%20noreferrer%20noopener%20noreferrer%22%3Epic.twitter.com%2F0BU8qW9f0S%3C%2FA%3E%3C%2FP%3E%E2%80%94%20Wictor%20Wil%C3%A9n%20(%40wictor)%20%3CA%20href%3D%22https%3A%2F%2Ftwitter.com%2Fwictor%2Fstatus%2F837300104591773696%22%20target%3D%22_blank%22%20rel%3D%22nofollow%20noopener%20noreferrer%20noopener%20noreferrer%22%3EMarch%202%2C%202017%3C%2FA%3E%3C%2FBLOCKQUOTE%3E%3CP%3EGive%20it%20a%20few%20more%20days%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-50663%22%20slang%3D%22en-US%22%3ERe%3A%20Code%20Formatting%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-50663%22%20slang%3D%22en-US%22%3E%3CP%3EIs%20there%20an%20update%20that%20allows%20this%20functionality%3F%26nbsp%3B%20I've%20closed%20and%20restarted%20Teams%20and%20didn't%20receive%20any%20notification%20of%20an%20update%2C%20tried%20to%20format%20some%20code%20and%20it%20didn't%20work%3A%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%60%60%60%3C%2FP%3E%3CP%3Epublic%20class%20TestMe%3C%2FP%3E%3CP%3E%7B%3C%2FP%3E%3CP%3E%26nbsp%3B%26nbsp%3B%26nbsp%3B%20public%20string%20TestSomething%20%7B%20get%3B%20set%3B%20%7D%3C%2FP%3E%3CP%3E%7D%3C%2FP%3E%3CP%3E%60%60%60%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-50656%22%20slang%3D%22en-US%22%3ERe%3A%20Code%20Formatting%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-50656%22%20slang%3D%22en-US%22%3E%3CP%3EThis%20feature%20is%20now%20available.%3C%2FP%3E%3CP%3EUse%20markdown%20syntax%20such%20as%20%26nbsp%3B%60code%60%20or%26nbsp%3B%3C%2FP%3E%3CP%3E%60%60%60%3C%2FP%3E%3CP%3Ecode%3C%2FP%3E%3CP%3E%60%60%60%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E(ie%20backticks)%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-45114%22%20slang%3D%22en-US%22%3ERe%3A%20Code%20Formatting%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-45114%22%20slang%3D%22en-US%22%3E%3CP%3EChecking%20back%20on%20this%20feature%20request%2C%20any%20timeline%3F%20%26nbsp%3BOnce%20this%20hits%2C%20we%20can%20say%20goodbye%20to%20HipChat%20forever.%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-41121%22%20slang%3D%22en-US%22%3ERe%3A%20RE%3A%20Code%20Formatting%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-41121%22%20slang%3D%22en-US%22%3E%3CP%3EAlso%20looking%20for%20any%20update%20on%20this%3F%20I've%20got%20my%20teams%20ready%20to%20switch%20off%20of%20Slack%20but%20the%20missing%20Code%20Snippets%20is%20a%20hurdle%20for%20getting%20developer%20buy%20in.%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-40198%22%20slang%3D%22en-US%22%3ERe%3A%20RE%3A%20Code%20Formatting%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-40198%22%20slang%3D%22en-US%22%3E%3CP%3EAny%20update%20on%20this%20feature%3F%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-28771%22%20slang%3D%22en-US%22%3ERE%3A%20Code%20Formatting%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-28771%22%20slang%3D%22en-US%22%3EYes%2C%20this%20is%20one%20of%20our%20most%20highly%20requested%20features%20and%20we%20will%20be%20adding%20support%20for%20code%20formatting%20very%20soon.%20Stay%20tuned!%20%3A)%3C%2Fimg%3E%3C%2FLINGO-BODY%3E
Highlighted
Keith Furman
Occasional Contributor

My developers miss the ability to format their pasted code like they used to in HipChat. Any plans on adding this soon?

 
21 Replies
Solution
Yes, this is one of our most highly requested features and we will be adding support for code formatting very soon. Stay tuned! :)

Any update on this feature?

Also looking for any update on this? I've got my teams ready to switch off of Slack but the missing Code Snippets is a hurdle for getting developer buy in.

Checking back on this feature request, any timeline?  Once this hits, we can say goodbye to HipChat forever.

This feature is now available.

Use markdown syntax such as  `code` or 

```

code

```

 

(ie backticks)

Is there an update that allows this functionality?  I've closed and restarted Teams and didn't receive any notification of an update, tried to format some code and it didn't work:

 

```

public class TestMe

{

    public string TestSomething { get; set; }

}

```

It might be still rolling out to tenants, but here it is in action:

And here it is; Markdown in #MicrosoftTeams: pic.twitter.com/0BU8qW9f0S

— Wictor Wilén (@wictor) March 2, 2017

Give it a few more days

It finally updated and YAY!  We have code formatting now.  Thanks so much for the great news Wictor!

This is great, thanks for the update.  Now the next logical question -- does it work on the mobile client?

Not yet...

Any plan to handle syntax highlighting?

Code formatting still not working here. Somebody mentioned it might be related to the language used for input (see https://microsoftteams.uservoice.com/forums/555103-public/suggestions/18532621-improved-markdown-sup... ). Is that a correct assumption and if so will it be fixed?

If you paste in the text of the code into the message box and then click on the Expand compose box for formatting button on the bottom left (it looks like an A with a paintbrush) Then at the top of the compose box there will be a drop down list of Paragraph formatting options, choose Code.


@Wictor Wilen wrote:

This feature is now available.

 

 


Any way to switch it off? Also, any way to switch off "Smart paste", wherein Teams tries to format stuff I've copied from elsewhere and into a Teams message. I do not - and never will - want the format copied between apps.

 

I'm fine with it having formatting shortcuts, but I want it to be an *active* choice on my part; I don't want Teams trying to be "helpful" and doing it for me.

 

/me remembers Clippy...

 

Cheers.

 

-- 

Adam

Hello, any idea when this is going to be added?

Given that paste strips out linefeeds, this is of very limited use. I don't tend to retype code from scratch :(

 

Although there is a way to paste pre-formatted code, it would be nice if this feature actually supported syntax highlighting like slack / hipchat.

Code formatting does not work when I use markdown. I tried Firefox, Chrome, Windows EXE, Android App, still no success. It makes my wonder that the MS support page (https://support.office.com/en-us/article/use-markdown-formatting-in-teams-4d10bd65-55e2-4b2d-a1f3-2b... )does show a working example:

Capture.JPGAny hints? - Thanks Markus

Make sure to use the backtick ` and not the single quote/apostrophe '

Same.  It just makes a gray box without any highlighting.
nohighlighting.PNG

Related Conversations
Tabs and Dark Mode
cjc2112 in Discussions on
35 Replies
Extentions Synchronization
Deleted in Discussions on
3 Replies
flashing a white screen while open new tab
Deleted in Discussions on
14 Replies
Stable version of Edge insider browser
HotCakeX in Discussions on
35 Replies
Security Community Webinars
Valon_Kolica in Security, Privacy & Compliance on
9 Replies