Adaptive Cards for Windows Developers
The first Windows experience to supports Adaptive Cards is Timeline, a brand new experience first introduced in Windows 10 1803.
Windows.ApplicationModel.UserActivities.UserActivity API is what populates an Activity into Timeline.
The Adaptive Card will be supplied via the
Content property of
VisualElement, as seen below:
UserActivity userActivity = await channel.GetOrCreateUserActivityAsync(activityId, new HostName("contoso.com")); userActivity.ActivationUri = new Uri("rss-reader:article?" + article.Link); userActivity.DisplayText = article.Title; //used for details tile text userActivity.VisualElements.Content = AdaptiveCardBuilder.CreateAdaptiveCardFromJson(jsonString); await userActivity.SaveAsync();
There is a great 45-min learn module that covers these steps end-to-end.
This session at Build 2017 covers User Activities in detail.
Other Windows Surfaces
We don't have anything to share just yet, but we're working on incorporating Adaptive Cards into more Windows experiences.
We've barely scratched the surface in this tutorial, so check back soon and browse the links below to explore more about Adaptive Cards.