question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[Rendering] Action.Submit in combination with Input.Number under Action.Showcard does not work

See original GitHub issue

Target Platforms

iOS, Android, Other

SDK Version

1.2

Application Name

Microsoft Teams

Problem Description

Tested on Teams for iOS, Android, Windows client and Teams web client and they all experience the same issue.

I have a flow in power automate that uses the “Post adaptive card and wait for a response” action.

The Action.Submit button under Action.ShowCard does not work if the input type is Input.Text in the “sub-adaptive card”.

If i change the input to Input.Text everything works as expected.

Screenshots

No response

Card JSON

{
    "$schema": "http://adaptivecards.io/schemas/adaptive-card.json",
    "type": "AdaptiveCard",
    "version": "1.2",
    "body": [
        {
            "type": "TextBlock",
            "text": "Status",
        },
        {
            "type": "Input.Text",
            "placeholder": "Status",
            "id": "txtStatus",
        }
    ],            
    "actions": [
        {
            "type": "Action.Submit",
            "title": "Submit status"
        },
        {
            "type": "Action.ShowCard",
            "title": "Submit something else",
            "card": {
                "type": "AdaptiveCard",
                "body": [
                    {
                        "type": "TextBlock",
                        "text": "Something:",
                        "wrap": true
                    },
                    {
                        "type": "Input.Number",
                        "id": "NumberOfDays"
                    }
                ],
                "actions": [
                    {
                        "type": "Action.Submit",
                        "title": "Set number",
                        "value": 3
                    }
                ]
            }
        }
    ]
}

Sample Code Language

No response

Sample Code

No response

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:5 (2 by maintainers)

github_iconTop GitHub Comments

2reactions
jwoo-msftcommented, Oct 5, 2021

Hi @jwoo-msft. I can give additional details in this issue because I’m really confident it’s the same problem. In my case, I’m using the Teams app to reproduce this, and so far I could do it on the following platforms: Windows desktop app, Android app, Web Here is a json that will reproduce the issue when you send it from AppStudio: { "type": "AdaptiveCard", "body": [ { "type": "Input.Number", "placeholder": "Placeholder text", "id": "quantity123" } ], "actions": [ { "type": "Action.Submit", "title": "OK" } ], "$schema": "http://adaptivecards.io/schemas/adaptive-card.json", "version": "1.2" } I also created a screen recording where you can see the following:

  1. Paste the json inside App Studio card editor
  2. Send the card to myself
  3. Open the message and type a number inside the card, in this case clicking on OK doesn’t do anything
  4. I delete the number and click on OK, now the action is submitted
  5. I enter ‘0’ in the input number, the action is submitted again
  6. I type a number, the action is not submitted

If you paste the json above inside the Adaptive Cards designer website, then the action will be invoked no matter what you type inside the input number. So I’m guessing the issue only involves Teams (that I know of).

Thanks for providing the JSON. I tried it. Yes, this is not reproducing on our sample apps. @RebeccaAnne, can you raise this issue with Teams?

0reactions
Wajeed-msftcommented, Oct 5, 2021

This issue has been copied over to Microsoft Teams repo here: https://github.com/MicrosoftDocs/msteams-docs/issues/4299

Read more comments on GitHub >

github_iconTop Results From Across the Web

Adaptive card with Action.ShowCard not rendering in MS ...
ShowCard example. We sent this card using power automate flow. It is rendered properly and is working fine. Attaching screenshots of the same....
Read more >
Action.ShowCard
The Adaptive Card to show. Inputs in ShowCards will not be submitted if the submit button is located on a parent card. See...
Read more >
Action.Submit
Submit", Yes, Must be "Action.Submit" . 1.0. data, string , object, No, Initial data that input fields will be combined with. These are...
Read more >
Input.ChoiceSet inside Action.ShowCard card not working ...
I'm using the node library npmjs.com/package/botbuilder Also if I try my sample using App Studio in Microsoft Teams it works fine, I can...
Read more >
Adaptive cards not rendering in iOS if "Action.ShowCard" is ...
I think I found the issue now: The problem seems to be the comment input field inside the nested card that is triggered...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found