Category: Development

Development

Microsoft Adaptive Cards 1.0 is now Available

image

During the Windows Developer Day 2018 keynote, Kevin Gallo talked about Adaptive Cards and how they can be used to provide a flexible way to present your content and your data.

Adaptive Cards gives you the tools to create scale across any engagement surface.

image

Adaptive Cards was first announced at the Microsoft Build 2017 conference and has now come out of preview and is generally available as a 1.0 product. When Windows 10 Spring Creators Update is released, you will be able to use Adaptive Cards on the Windows Timeline along with other experiences like a bot, Skype, Notifications, Teams and so much more.

Enjoy!

References

Windows Developer Day 2018 Keynote

http://adaptivecards.io/

https://github.com/Microsoft/AdaptiveCards/releases/tag/v1.0

Development

Visual Studio 2017 (15.6) has new Update Experience

After updating to Visual Studio 2017 (15.6) earlier today I noticed a minor update is out (15.6.1) and you will notice a new update experience as shown here. The updated dialog shows the current version, the update version and a link for the release notes:

image

image

This update (15.6.1) only takes a couple minutes to apply.

Enjoy!

DevelopmentMobile

Troubleshooting the installation of Xamarin Android Device Manager

UPDATED: Feb 26 2018 (later that day)

This post is a follow up to how I got Xamarin Android Device Manager up and running on Windows. Please read the Xamarin Developer guide first which explains how to install and use the Xamarin Android Device Manager for Visual Studio on Windows (or for Mac). Please keep in mind that at the time of this post the Xamarin Android Device Manager is still in preview.

For me I’m running the latest version of Visual Studio 2017 (15.5.7) and I already had the Xamarin components installed and working. Up until now I wasn’t really using the Android emulators for any Xamarin development as I was more focused on iOS and Windows. However now I have a need to and so I decided to try out the new Xamarin Android Device manager. Why you might ask? Well as of Android SDK Tools version 26.0.1, Google has removed support for their UI-based AVD and SDK managers in favor of their new CLI (Command Line Interface) tools.

After having installed the latest version of the Xamarin Device Manager installer for Windows, I ran it from the Start menu with Administrator privileges like so:

sshot-360

And this is the error I get:

sshot-360-1

I ran through the troubleshooting section section and the issue is that I was missing the Android SDK (requires 26 or higher). Perhaps a one of the latest Visual Studio updates caused this issue because now none of the Android tooling like device or emulator are working. Perhaps installing the Xamarin Device Manager broke it, I’m not sure but it’s broken. The only way I was able to resolve this was to run the Visual Studio Installer and uninstalled the the Xamarin SDK Manager and re-install it. Here is what I did.

My Solution to Fixing Missing Android SDK

1. Run Visual Studio Installer and then click on the Modify button:

image

2. Now go to the Individual components tab and Remove Xamarin SDK Manager and then click on the Modify button to apply the changes. Take notice of the amount of disk space that will be freed up. For me it was 113 MB.

image

3. Now do steps 1 and 2 again but this time add back the Xamarin SDK Manager and then notice the amount of disk space required for these changes…for me it was 1.4 GB, obviously something screwed up and I was missing a great deal. Now apply the changes by clicking on the Modify button.

Now when you run the Xamarin Android Device Manager from the start menu (with administrator rights) it should load up as expected. Now if you are like me and don’t have the latest Android SDK Tools, then you are then presented with the following dialog prompting you to download them from the Xamarin Android SDKs and Tools manager:

sshot-361

When the Xamarin Android SDK and Tools manager opens, review the SDK platforms you want installed and then click over to the Tools tab:

sshot-362

In the Tools tab, expand the Android SDK Tools selection and change the selected tooling to the current version which is 26.1.1 and then click on the Apply Changes button. If you’re just changing the Android SDK Tools, this should only take a couple min at most to apply. Once it’s done close down the Android SDKs and Tools manager.

sshot-363

Now go back to Visual Studio (re-run if you have it running already) and run the Android Emulator Manager from the Tools – > Android menu.

image

You will now be presented with the new Android Devices manager. When you first launch the Android Device Manager, it presents a screen that displays all currently configured virtual devices. For each device, the Name, Operating System (Android API Level), CPU, Memory size, and screen resolution are displayed:

image

I then went on and added a new option for Android Oreo and when I tried to run it I got another error:

image

Now it looks like I need to install another tool, Intel’s HAXM which requires Hyper-V be disabled.

Summary

What seemed like a quick and easy update has turned into quite the adventure. It’s 2018…why can’t this be more simple!

Enjoy!

References

Channel 9 | The Xamarin Show: Snack Pack | The New Xamarin Android Device Manager

How to setup and create Android virtual devices using Xamarin Android Device Manager

Installing Xamarin.Android on Windows

Installation Instructions for Intel® Hardware Accelerated Execution Manager (Intel® HAXM) – Microsoft Windows*

DevelopmentEvents

Windows Developer Day–March 7, 2018

WindowsDeveloperDay-Mar72018

On March 7, 2018 at 9:00 AM PST, Microsoft will livestream a Windows Developer Day event on the latest news on tools and features for developers that will be coming in the next Windows 10 Update. The livestream will cover a keynote by Kevin Gallo, CVP of the Windows Developers Platform and then be followed by a Q&A session.

No matter what you’re working on, you’ll find plenty of improvements that will make your software even more compelling. You’ll also get inside info on:

  • Building for the modern workplace—Learn how Windows is evolving as a platform to make improving and updating your existing Windows code with new functionality as simple as possible.
  • Making your software part of the intelligent edge—Give your applications the capability to quickly make complex calculations and inferences, enabling them to become a native part of the intelligent edge.

Windows Developer Day is the only place to find out what’s coming for developers in the next Windows 10 Update, so RSVP today.

Enjoy!

Resources

Windows Developer Day

AzureDevelopmentPresentationsTechnology

An Introduction to Serverless Compute with Azure Functions–My presentation at CTTDNUG

AzureFunctions-e1491294484596

Last week I did a presentation on Azure Functions at Canada’s Technology Triangle .NET User Group (CTTDNUG) in Kitchener, Ontario. One of the audience members was kind enough to film the presentation and post it on YouTube.

Here is a link to my presentation on An Introduction to Serverless Compute with Azure Functions.

Enjoy!

References

https://www.youtube.com/watch?v=bPMzW10pECQ&feature=youtu.be

Development

Building a Better Napkin/Whiteboard, Go from Ink to Code

image

Microsoft’s Garage lab has announced a new Ink to Code app that will take your digital ink sketches and turn them into an actual application. Ink to Code is a UWP app that enables developers to draw a wire frame sketch and then export that sketch into source code for use in Visual Studio.

Urban legend has it that some of the greatest ideas in history started with a napkin. The Gettysburg Address, the poem that gave way to the U.S. National Anthem, and the premise of the Harry Potter series—each were reportedly born into the world through the medium of sketches on scrap paper—and when app creators put pen to paper for their ideas, this is often a canvas of choice. While rapid prototyping with the napkin and the whiteboard holds its charms, less charming is the prospect of translating quick sketches into working code. – Lainie Huston

Ink to Code is supposed to use artificial intelligence and automation to create the code from the wire frame sketches and at this time only supports basic visual elements like labels, text fields, images and buttons. This visual element recognition is similar to what you can find in the Microsoft Whiteboard (Preview) app, which you can download from the Microsoft Store.

This app currently supports Android and Windows UWP apps. At this time the app doesn’t seem to be available on the Microsoft Store, so keep an eye out for it.

Enjoy

References

https://www.microsoft.com/en-us/garage/blog/2018/01/napkin-disrupted-meet-ink-code-microsoft-garage-project/

https://www.microsoft.com/en-us/garage/profiles/ink-to-code/?group=newest

https://www.thurrott.com/windows/windows-10/150989/microsofts-new-app-turns-basic-sketches-code

Development

We Can’t Do That In One Sprint

I came across a great software development post on Hackernoon called We Can’t Do That In One Sprint. This is basically where Product comes to the development team with an idea of a new feature or product and they want to know how long it will take to develop and get to production as quickly as possible.

1_siePcBn2yZOKxF6bnDyp1g@2x

Too often have I experienced what is outlined in this article. I agree that it’s best to do small chunks of work and get it out to production and then iterate on the feature. What I find is that this fails when Product doesn’t give Development enough time to iterate and cuts the timeline short and moves on. Maybe this is what the business wants/needs but sometimes it leads to features being half baked, released to production, rarely iterated on and then future features are built on this feature.

As the author says, “There is NO silver bullet. Get SOMETHING out there in one sprint.”

Enjoy!

References

https://hackernoon.com/we-cant-do-that-in-one-sprint-a6780d67480

Development

The Windows 10 Fall Creators Update SDK is now available to download

windows-10-fall-creators-update-sdk

The Windows 10 Fall Creators Update SDK is now available to download.

Want to catch up on what’s included in the Windows 10 Fall Creators Update, take a look at the Windows Developer Day keynote or dive deeper with 18 additional videos. The Windows Developer Day videos are now available to view here.

Enjoy!

References

Download the Windows 10 Fall Creators Update SDK

Watch the Windows Developer Day – Fall Creators Update keynote and other sessions

Development

GitHub for Visual Studio now allows Pull Request Comments from IDE

0917vsm_github_vs

GitHub for Visual Studio 2.3 was recently released and it brought new functionality that now allows you to add pull request comments directly from the IDE.

To get started you  will need the latest version of GitHub Extension for Visual Studio. Next open up a pull request from the GitHub pane and while viewing a file you can click on the left gutter (see blue plus button) to add your feedback, all without leaving Visual Studio.

image

This functionality is still pretty limited but its a step in the right direction. I look forward to more GitHub online functionality making it’s way to this great extension.

Enjoy!

References

Inline comments in GitHub for Visual Studio

DevelopmentDevOps

Visual Studio Team Services Build to the Rescue

So this week Visual Studio Team Services build and release saved me and my team.

At our company we have configured an on premise continuous integration server along with build agents using TeamCity which is a product from JetBrains. TeamCity Professional is actually a free application that allows you to run 3 build agents. The only cost is the associated hardware and Windows licensing. I fell in love with TeamCity years ago when I set it up at our company and it’s been a very stable and a versatile CI server since. However this week I ran into some issues with our TeamCity server and the fact that it was on premise only added to the problem. Let me explain.

Our build server physical infrastructure is actually located offsite from our office (along with other dev/qa servers), so when I say on premise I really means its dedicated hardware that we own and not up in the cloud. The situation we ran into is that our TeamCity server didn’t restart properly and was unavailable by remote access by the ITOPS team, this meant someone had to go to the offsite location and reboot the server. Now you might be wondering, why don’t you have a backup…a good question and something I’ll be looking into.

What made matters worse is that we we’re nearing the end of a regression cycle and we wanted to deploy later this week. So having our build server drop off the grid was just bad timing and it meant DEV and QA were in a holding pattern while we waited for our build server to be brought back up and hopefully it was ok and not corrupted or worse.

While we waited for our build server to be restarted I started thinking about worse case scenarios like what if our build server is dead and we need to rebuild or restore from a backup (and what do you know it was out of date). None of these options can be done quickly and they require unplanned resources from the ITOPS team and myself.

Having already explored Visual Studio Team Services (VSTS) build and release services for my personal development and that of our Live .NET logging tool ReflectInsight, I knew I could easily and quickly get one of our applications setup in that continuous integration pipeline. You will actually be shocked at how quickly I got things going.

Our current build process typically builds the solution, runs unit tests, creates a nuget package and then finally publishes the nuget package to an internal nuget repository that is part of TeamCity. We then have an automated deployment service called Octopus Deploy that picks up this package and can then deploy to any of our QA and/or production systems. Since our TeamCity server is offline, I would need to publish the nuget package to another destination for the time being. I decided to create an Azure Storage account and then copy the nuget package there. I could then pull the nuget package down and manually upload to our Octopus Deploy server.

To get started I headed over to my Visual Studio Team Services account I had setup with my MSDN subscription and I then created a new project to contain my builds. I then clicked on the Build & Release tab and then clicked on the New button to create a new build definition:

image

I then clicked on the ASP.NET (PREVIEW) featured template:

image

I then configured the Get sources task to point to our GitHub repository and then I added in the last two steps for generating a NuGet package and to copy the generated NuGet package to an Azure Storage account:

image

I wont go into detail for each of these build tasks as their pretty straight forward, but after I had everything setup and tested, I looked at the clock and it was under 15 min from start to finish. That is something I could never have done in our existing on premise build infrastructure and it now looks like I have my backup solution.

One of the nice things about using the hosted agent in VSTS is that it’s located in Azure and its a service that is managed by the Azure team. This means I spend more time focusing on developing my applications and less time worrying about managing the associated build infrastructure and what happens if a server goes down, performing backups, restores and that all hands on deck feeling when your infrastructure goes down at the worse possible time.

Enjoy!

References

TeamCity

Visual Studio Team Services

Azure Storage Explorer

Octopus Deploy