SharePoint List JSON Formatting – MS Chat link
In SharePoint, when you hover over or click a profile image, it opens the contact details with option to “Start Chat” — is there a way to create this link in JSON? Or a way to click a link and open MS Teams directly to chat with the person?
I’m currently using the following, which works but it first opens Teams on the current browser tab and user has to select either open on client or continue on the web:
{
“elmType”: “a”,
“attributes”: {
“iconName”: “Chat”,
“href”: “=’https://teams.microsoft.com/l/chat/0/0?users=’ + [$ContactPersonEmail]”,
“title”: “=’Chat with ‘ + [$FirstName] + ‘ in Teams'”,
“class”: “ms-fontColor-neutralPrimary ms-fontColor-themePrimary–hover”
},
“style”: {
“text-decoration”: “none”
}
}
I tried the following but neither worked:
“href”:”=’msteams://teams.microsoft.com/l/chat/0/0?users=’ + [$ContactPersonEmail]”
“href”: “=’sip:’ + [$ContactPersonEmail]”
In SharePoint, when you hover over or click a profile image, it opens the contact details with option to “Start Chat” — is there a way to create this link in JSON? Or a way to click a link and open MS Teams directly to chat with the person?I’m currently using the following, which works but it first opens Teams on the current browser tab and user has to select either open on client or continue on the web: {
“elmType”: “a”,
“attributes”: {
“iconName”: “Chat”,
“href”: “=’https://teams.microsoft.com/l/chat/0/0?users=’ + [$ContactPersonEmail]”,
“title”: “=’Chat with ‘ + [$FirstName] + ‘ in Teams'”,
“class”: “ms-fontColor-neutralPrimary ms-fontColor-themePrimary–hover”
},
“style”: {
“text-decoration”: “none”
}
} I tried the following but neither worked: “href”:”=’msteams://teams.microsoft.com/l/chat/0/0?users=’ + [$ContactPersonEmail]” “href”: “=’sip:’ + [$ContactPersonEmail]” Read More