March 2013

Volume 28 Number 03

Editor's Note - Developing Apps for Office

By Michael Desmond | March 2013

Michael DesmondThe past two issues of MSDN Magazine have included feature articles focused on developing applications for Microsoft Office 2013. Last month’s lead feature (“Exploring the New JavaScript API for Office”) detailed the object model hierarchy of the JavaScript API for Office and explored the object model’s asynchronous pattern.

In this issue, authors Stephen Oliver and Eric Schmidt, both programming writers in the Office Division at Microsoft, shift their sights to handling data in apps for Office (“Exploring the JavaScript API for Office: Data Access and Events”). They show how developers can get and set selection data and how to get all of the file data. They also look at the events in the JavaScript API for Office and how to code against them.

The apps for Office platform represents an important change in the way apps are developed for the Office suite. The new platform leverages Web connectivity and standard technologies such as HTML5, XML, CSS3, JavaScript and even server-side technologies like ASP.NET. In essence, an app for Office is a Web page that’s hosted inside an Office client application such as Word or Excel, and can extend the functionality of a workbook, presentation, project, e-mail message, or appointment.

Developers can continue to build Office extensions using existing tools and platforms such as Visual Studio Tools for Office (VSTO) and Visual Basic for Applications (VBA), both for older and current versions of Office. However, these apps won’t leverage the Web technologies in apps for Office, and aren’t eligible for distribution via the Office Store. On the flip side, don’t expect to deploy your new apps for Office to older versions of the suite. The new apps are currently compatible with Office 2013 and Office 365 (

We’re already seeing the first apps for Office in the wild. At the end of January Microsoft released Bing Apps for Office (, a collection of five free apps powered by the Bing search engine: Bing Finance for Office, Bing Maps for Office, Bing Image Search for Office, Bing News Search for Office and Bing Dictionary for Office. The apps work with Office 2013 and Office 365.

I checked in with Oliver and Schmidt about their experience with apps for Office and the new JavaScript API for Office. Oliver, a Microsoft Certified Professional Developer who writes developer documentation for Excel Services and Word Automation Services, says he’s most impressed by the way apps for Office lets developers integrate Web assets and resources into Office applications.

“I’m attracted to the concept inherent in the JavaScript API for Office—that of bringing the Web to the Office application. And since a wide range of Web programming technologies are available to you in this new model, you can use familiar technologies like simple REST calls to bring data to or from the Web right from within your Office application,” he says.

Schmidt jokes that he “giggled like a child” when he saw how easy it was, with Internet Explorer 10, to use HTML5 features in an app, such as add an input element with a placeholder attribute. He also says upgrading apps for Office is incredibly easy, as developers need only republish HTML, JavaScript and CSS files to the Web server.

“I also have a special fondness for bindings,” Schmidt adds. “Since task pane and content apps travel with the files that they’re inserted into, we needed a way for an app to retain a reference to a specific region in the document. Bindings allow us to do that.”

So what advice do the authors have for developers intrigued by the new opportunities presented with Office 2013?

“I’d say, jump in and start playing with the API,” says Oliver. “While the spectrum of apps you can develop is fairly wide—from the relatively simple app that just grabs some data out of the document to a more-sophisticated app that pushes/pulls data to/from a back-end system—I think it’s super easy for a developer new to the platform to get in and explore the API and get a feel for what they might be able to do with it.”

He suggests that developers check out the “Napa” Office 365 Development Tools Web site (, which makes it easy to start exploring the API. Oh, and one more thing:

“Hey, I’m a doc guy,” Oliver says, “so I encourage those getting started to take a look at our documentation ( and give us feedback on where we can improve it.”

Michael Desmond is the Editor-in-Chief of MSDN Magazine.