This project is read-only.

Get TypeScript Addon

For Visual Studio 2015 you can get the latest version from here:
In Visual Studio 2017 you have to just mark it during the installation as a component. It will automatically keep up-to-date.

create new web-project

  • Open Visual Studio
  • Create "New Project..."
  • Choose the "ASP.NET Web Application (.Net Framework)" template
  • Select the "Empty APS.NET Template (you don't need anything more)
  • wait until the project is initialized
  • in the project root create a new subfolder "Design"
  • copy the two files (Xrm.d.ts and Xrm.Utility.d.ts) into that location

configure you visual studio

  • navigate to the project settings (double click the "Properties" node in the project explorer
  • move into "TypeScript Build" tab
  • choose ECMAScript 5 as version
  • and CommonJS as module system

now its time to start developing

  • create a new file in your project root and choose the TypeScript template
  • simply start typing.... try this:

    function helloWorld() {
       var attribute = Xrm.Page.getAttribute("fullname");
       Xrm.Utility.alertDialog("Hello " + attribute.getValue());

Last edited Feb 12, 2017 at 5:13 PM by LarsMueller, version 1