Templates - James Montemagno https://staging.montemagno.com/tag/templates/ https://staging.montemagno.com/content/images/2017/08/MonogramIcon_Orange_NoBuffer.png Templates - James Montemagno https://staging.montemagno.com/tag/templates/ Hugo -- gohugo.io Tue, 13 Oct 2026 23:21:57 GMT 60 The Xamarin.Android Template Pack Returns for VS 2017 https://staging.montemagno.com/xamarin-android-template-update-vs-2017/ 59a08e8087dd150022358227 Fri, 25 Aug 2017 20:55:50 GMT A few years back I published some awesome Xamarin.Android item and project templates to simplify development with Android’s AppCompat libraries. The item templates have actually found their way into Visual Studio, which is pretty awesome: ItemTeplates

What about the project templates? Well I am hoping for this fall to unleash brand new templates for Xamarin.Android directly in the box, but until then I have updated my Visual Studio template pack for Visual Studio 2017 and it now includes:

Blank & Single-View Apps based on AppCompat

BlankApp

NavigationDrawer

Bottom Navigation App

BottomNavigation

Tabbed App

Tabs

This new template pack is available right now in VS 2017 and gives you everything you need to start making beautiful Xamarin.Android applications. You can find the source on GitHub as well!

]]>
New & Improved Xamarin.Android Templates for Visual Studio https://staging.montemagno.com/new-improved-xamarinandroid-templates-for/ 598df8f2c121b60019bf3005 Fri, 10 Jul 2015 00:38:21 GMT

It has been a bit over a year since I first introduced my Xamarin.Android Templates pack for Visual Studio and things sure have changed in the world of Android since then. Early on the templates pack only introduced a few item templates for menu items and a simple implementation of the Navigation Drawer, my favorite way to navigate in Android. Then this March Google went and changed everything with AppCompat and the introduction of the new Toolbar. I rushed to update all of my templates to include all these nice new features. It looks like it is that time of the year again with the new Android Design Support Library, which yet again changes how we implement the Navigation Drawer and of course let’s not forget about the big change to AppCompatActivity. 

I am pleased to announce the latest release of my templates that incorporate all of these changes to make it easy to get up and running with AppCompat and the new fancy navigation drawer featuring the NavigationView.

You can grab these templates from the Visual Studio Gallery by going to “Tools->Extensions and Updates” in any flavor of Visual Studio and searching for Xamarin.Android Templates. 

Once installed you will see a few new Project Templates under Android to create a blank app that features AppCompat or a full Navigation Drawer enabled app also featuring AppCompat:

Once you have your app up and running you might want to add a few new menu items such as search, share, or just a menu item and I have you covered:

Of course everything is open source on GitHub so you take take a peek at what I am doing in the templates. Additionally, if you already have an app and are looking to upgrade your navigation drawer or tabs to the new material support library implementations then look no further than my Xam.NavDrawer GitHub repo that has been updated with an awesome new example! 

I hope you enjoy these new updated templates and I look forward to your feedback or suggestions for future updates!

]]>
Essential Xamarin.Android Templates for Visual Studio Extensions and Updates”. I like the templates that come installed with Xamarin, however the flexibility of Visual Studio to easily create project and item templates led me to creating this pack which included: ]]> https://staging.montemagno.com/essential-xamarinandroid-templates-for-visual/ 598df8f2c121b60019bf3010 Mon, 09 Mar 2015 21:03:50 GMT During my Effective Navigation in Android talk at last years Xamarin Evolve I had the opportunity of showcasing my Xamarin.Android Templates Pack for Visual Studio, which you can get from the Visual Studio Gallery under “Tools->Extensions and Updates”. I like the templates that come installed with Xamarin, however the flexibility of Visual Studio to easily create project and item templates led me to creating this pack which included:

Project:

  1. Navigation Drawer

Item:

  1. Single Menu Item
  2. Search Menu Item
  3. Share Menu Item

While these were great at the time the entire Android ecosystem has shifted towards AppCompat for Material Design in apps. So I worked all day and night Sunday to update my Templates pack to bundle in a bunch of AppCompat project templates, and also extended the item templates to include AppCompat versions. 

Android Blank App AppCompat 

The first template creates a standard blank app, but adds all resource files for you automatically for theming as well as some simple navigation. It also uses the new Toolbar.

Android Navigation Drawer AppCompat 

Probably the most requested template and most used is a nice Navigation Drawer sample with everything you need including images in your navigation drawer and proper selector colors for older API levels.

All The Menu Templates!

I have also update all of the Menu Item xmls to include a standard and AppCompat version. I also have the code that you need to copy into your Activity so you don’t need to go look it up!

One More Thing

I also decided to include a nice Adapter item template with my recommend method of proper view reuse, which you can read more about at http://blog.xamarin.com/creating-highly-performant-smooth-scrolling-android-listviews/. This way you don’t have to remember all that nasty ViewHolder logic. I do plan on introducing a RecyclerView Adapter in the future as well. 

Requests Welcome

All of my project and item templates can be found on GitHub: https://github.com/jamesmontemagno/xamarin-templates and you are free to open up an Issue with a request for Android project or item templates that you might like to see.

Demo

I also decided to do a walkthrough of the templates:

]]>
Xamarin.Android Templates Pack! https://staging.montemagno.com/xamarinandroid-templates-pack/ 598df8f2c121b60019bf3038 Sun, 30 Mar 2014 03:31:59 GMT Xamarin.Android already ships with a bunch of great project templates for Visual Studio, however I find that there are a few things missing. I usually start a new project with a Navigation Drawer and I am always adding new Menus, but I can never seem to remember every little bit of XML that is needed for some complex menus such as share and search. This is why I have created the Xamarin.Android Templates Pack. This is the first release that includes these items that I have listed. You can download it immediately from the Visual Studio Gallery and browse the code on GitHub.

Included in the Menu Items are not only the XML required but also the code behind that will help you implement it. Once you have the Template pack installed you will see the items when you starter a new project or add an item to the menu folder in Resources.

Navigation Drawer:

Menu Item:

Share Menu:

Search Menu:

I am going to be continuing to add more and more templates and please feel free to add an issue or do a pull request if you want to see something.

]]>