Build a Reusable View Component in ASP.NET Core

View Components have been added to ASP.NET MVC to replace functionality previously accomplished using partial views. It is possible to include reusable components in their own class library and consume them in multiple MVC projects. This post walks through the steps required to create a dynamic navigation menu that is then inserted into an MVC…

0

Using Data-binding with Angular 2 to disable a button

I received a question from a customer new to AngularJS asking for the right way to disable a button until at least one checkbox was checked. The customer’s first thought was to recognize an event on the checkbox and react to it, but this is not necessary with the data-binding feature of Angular. You can…

0

File order matters with TypeScript inheritance

If you receive the following JavaScript error and your code contains a TypeScript class derived from another class, it is likely that your parent class has not been defined prior to the definition of your child class. Unable to get property ‘prototype’ of undefined or null reference To see the actual error, you will need…

1

Implementing a Save Warning in an Angular SPA

I have an Single Page Application written in AngularJS and need to provide a warning to the user if he or she attempts to close a window without saving. Since Angular automatically updates the DOM with a dirty flag this should not be a difficult feature to implement. However, it becomes more difficult when the…

0

Rules for the list name used with ListData.svc

The ListData.svc web service introduced with SharePoint 2010 offers a great option for querying a list to be consumed by JavaScript. The syntax is: http://<sharepoint-server>/_vti_bin/ListData.svc/<list-name> Determining the correct list name may not be obvious and there are a number of rules of which you should be aware. To illustrate we will use an example list…

1

Using OAuth in an App for Office

I will walk through the steps to combine an ASP.NET MVC5 application with an App for Office to allow the app to authenticate using a Microsoft Account or using Facebook. Similar steps could also be followed to authenticate using Google. Step 1 (Create an App for Office) Using Visual Studio 2013 or Visual Studio 2012…


About Me

I am a consultant in the Premier Developer Practice at Microsoft where I guide customers in the architecture, design and implementation of software solutions. My areas of expertise are in .NET, HTML5, JavaScript, SharePoint, and Office. My support is through hands-on workshops, remote webcasts, proof of concept work, and side-by-side assistance as developers migrate to…