I’m coding a Telegram-bot using MS Bot Framework. I want to use Attachments to collect data from user’s selection/choice. Would someone kindly help me with the following:
- How to put attachments side-by-side(columns & rows), and make them sizeable? Sample please?
- Is it possible to write an iteration code to create rows/columns from a list/Dict?
Thanks.
I attempted to code as per this sample:
var _card = new HeroCard
{
Text = "You can upload an image or select one of the following choices",
Buttons = new List<CardAction>
{
new CardAction(ActionTypes.ImBack, title: "Part1", value: "1"),
new CardAction(ActionTypes.ImBack, title: "Part2", value: "2"),
new CardAction(ActionTypes.ImBack, title: "Part3", value: "3"),
new CardAction(ActionTypes.ImBack, title: "Part4", value: "4"),
},
};
var _reply = MessageFactory.Attachment(_card.ToAttachment());
await turnContext.SendActivityAsync(_reply, cancellationToken);