SOLVED

Emojis in adaptive cards

Copper Contributor

Hi,

 

Is there a way to send emojis as part of a TextBlock, or other type of element ?

 

Thanks

2 Replies
best response confirmed by ChetanSharma-msft (Microsoft)
Solution

‌‌@__arik__ -The correct way to use emojis is to directly add it with Text like this "🥰 "
Code snippet:

{
    "type": "AdaptiveCard",
    "body": [
        {
            "type": "ColumnSet",
            "horizontalAlignment": "Center",
            "columns": [
                {
                    "type": "Column",
                    "items": [
                        {
                            "type": "ColumnSet",
                            "horizontalAlignment": "Center",
                            "columns": [
                                {
                                    "type": "Column",
                                    "items": [
                                        {
                                            "type": "TextBlock",
                                            "text": "**AwareGO Training Bot**",
                                            "wrap": true
                                        },
                                        {
                                            "type": "TextBlock",
                                            "spacing": "None",
                                            "text": "Hi ABC:🥰",
                                            "height": "stretch",
                                            "wrap": true
                                        },
                                        {
                                            "type": "TextBlock",
                                            "text": "Well, here you’ll receive the original, bite-sized video lessons that make learning about cybersecurity surprisingly fun :popcorn:.",
                                            "wrap": true,
                                            "isSubtle": true
                                        }
                                    ],
                                    "width": 250
                                }
                            ]
                        }
                    ],
                    "width": 100
                }
            ]
        }
    ],
    "$schema": "http://adaptivecards.io/schemas/adaptive-card.json",
    "version": "1.2"
}

Card UI:

 

AC1.png

Thanks, 

Sayali

--------------------------------------------------------------------------------------

If the response is helpful, please click "**Mark as Best Response**" and like it. You can share your feedback via Microsoft Teams Developer Feedback link. Click here to escalate. 

 

@__arik__ -Could you please confirm if your issue has resolved with above suggestion or still looking for any help?
1 best response

Accepted Solutions
best response confirmed by ChetanSharma-msft (Microsoft)
Solution

‌‌@__arik__ -The correct way to use emojis is to directly add it with Text like this "🥰 "
Code snippet:

{
    "type": "AdaptiveCard",
    "body": [
        {
            "type": "ColumnSet",
            "horizontalAlignment": "Center",
            "columns": [
                {
                    "type": "Column",
                    "items": [
                        {
                            "type": "ColumnSet",
                            "horizontalAlignment": "Center",
                            "columns": [
                                {
                                    "type": "Column",
                                    "items": [
                                        {
                                            "type": "TextBlock",
                                            "text": "**AwareGO Training Bot**",
                                            "wrap": true
                                        },
                                        {
                                            "type": "TextBlock",
                                            "spacing": "None",
                                            "text": "Hi ABC:🥰",
                                            "height": "stretch",
                                            "wrap": true
                                        },
                                        {
                                            "type": "TextBlock",
                                            "text": "Well, here you’ll receive the original, bite-sized video lessons that make learning about cybersecurity surprisingly fun :popcorn:.",
                                            "wrap": true,
                                            "isSubtle": true
                                        }
                                    ],
                                    "width": 250
                                }
                            ]
                        }
                    ],
                    "width": 100
                }
            ]
        }
    ],
    "$schema": "http://adaptivecards.io/schemas/adaptive-card.json",
    "version": "1.2"
}

Card UI:

 

AC1.png

Thanks, 

Sayali

--------------------------------------------------------------------------------------

If the response is helpful, please click "**Mark as Best Response**" and like it. You can share your feedback via Microsoft Teams Developer Feedback link. Click here to escalate. 

 

View solution in original post