Session 2: Office as a development platform with Visual Studio 2008

2,547 views

Published on


What's new in Smart Client Development

Do you build rich client applications? If so, you'll want to make sure that you're aware of all Microsoft's client-development technology. This event will showcase a wealth of new and forthcoming technology, including Visual Studio 2008.

Agenda:
Session 1: Building Rich Clients on the Microsoft Platform - Martin Parry
People want compelling user experiences supported by powerful online services. Microsoft's platform and tools empower developers to build both the rich client and the service. In this session we'll concentrate on some recent and forthcoming technologies that enable rich client apps: Visual Studio 2008, WPF, SQL Server Compact Edition and ClickOnce to name but a few.

Session 2: Office as a development platform with Visual Studio 2008 - Daniel Moth
The 2007 Microsoft Office System is extensible like never before. In this session we'll look at the numerous ways to extend the various Office applications such as Word, Excel, Outlook and others. Customisations demonstrated will include the new designers and templates for the Ribbon, Actions Pane, Task Pane, Content Controls and Form Regions. This will all be done in managed code from within Visual Studio 2008 and we will also see how to interop in both directions with VBA code.

For more details and the original slidedeck visit http://www.microsoft.com/uk/msdn/events/new/Detail.aspx?id=115

1 Comment
0 Likes
Statistics
Notes
  • Be the first to like this

No Downloads
Views
Total views
2,547
On SlideShare
0
From Embeds
0
Number of Embeds
12
Actions
Shares
0
Downloads
40
Comments
1
Likes
0
Embeds 0
No embeds

No notes for slide
  • Session 2: Office as a development platform with Visual Studio 2008

    1. 1. Office as a development platform with Visual Studio 2008 Daniel Moth Developer and Platform Group Microsoft http://www.danielmoth.com/Blog
    2. 2. AGENDA <ul><li>VSTO Overview </li></ul><ul><li>Office Ribbon Designer </li></ul><ul><li>Custom Task Pane </li></ul><ul><li>Action Pane </li></ul><ul><li>Outlook Form Region Designer </li></ul><ul><li>Word Content Controls </li></ul><ul><li>VBA <-> VSTO interop </li></ul><ul><li>ClickOnce Deployment </li></ul>
    3. 4. Roadmap <ul><li>Custom Document ActionsPane </li></ul><ul><li>Host Controls on document surface </li></ul><ul><li>Cached data in the document </li></ul><ul><li>Server-side data processing </li></ul><ul><li>Application-level add-ins for Outlook </li></ul>2007 2003 <ul><li>App-level add-ins for most popular Office apps </li></ul><ul><li>Runtime support for key Office 2007 UI elements (Custom Taskpane, Ribbon, Outlook form regions) </li></ul><ul><li>Runtime support enabling Office 2003 doc-level customizations to run in Office 2007 </li></ul>2007 2003 <ul><li>Workflow & Microsoft SharePoint support </li></ul><ul><li>Office 2007 system-specific features, file format, UI </li></ul><ul><li>App-level add-ins for more client applications </li></ul><ul><li>Deeper server-side programming </li></ul><ul><li>VSTO fully integrated into Visual Studio 2008 </li></ul>
    4. 5. VSTO Functionality Over Time <ul><li>Doc-level </li></ul><ul><li>Outlook add-ins, </li></ul><ul><li>VSTA in InfoPath </li></ul><ul><li>functional extensions </li></ul><ul><li>infra investments </li></ul><ul><li>11 Office add-ins, </li></ul><ul><li>infra investments </li></ul><ul><li>SP Workflow, </li></ul><ul><li>new designers, </li></ul><ul><li>functional extensions </li></ul><ul><li>infra investments </li></ul>
    5. 6. Doc-Level Version Resilience <ul><li>v1 solutions use the VSTO v1 runtime </li></ul><ul><li>v2 solutions use the VSTO v2 runtime </li></ul><ul><li>v3+ solutions use the VSTO v3+ runtime </li></ul><ul><ul><li>Reduces the number of runtimes (improves performance, working set) </li></ul></ul><ul><ul><li>Eliminates type name clashes in DefaultDomain </li></ul></ul><ul><li>Based on the Managed Add-in Framework </li></ul><ul><li>Common VSTO/VSTA runtime </li></ul>
    6. 7. Set the scene inc document level addins
    7. 8. “ Fluent” UI Ribbon, Custom Task Panes, Actions Pane, Form Region
    8. 9. Office Ribbon <ul><li>New Look and Feel for Office UI </li></ul><ul><li>Replaces Command Bars in “the big 5” Office apps </li></ul><ul><li>Introduces a new extensibility model: RibbonX </li></ul><ul><li>Enables you to </li></ul><ul><ul><li>Customize office tabs, Add to built-in tabs </li></ul></ul><ul><ul><li>Remove tabs, groups and controls </li></ul></ul><ul><ul><li>Add to Office menu, Override built-in UI </li></ul></ul>Tab Group Control Ribbon
    9. 10. XML-based Customisation Support Ribbon XML structure requires a specific hierarchy <customUI xmlns=&quot;http://schemas.microsoft.com/office/2006/01/customui&quot; onLoad=&quot;OnLoad&quot;> <ribbon> <tabs> <tab idMso=&quot;TabAddIns&quot;> <group id=&quot;MyGroup&quot; label=&quot;My Group&quot;> <toggleButton id=&quot;toggleButton1&quot; size=&quot;large&quot; label=&quot;My Button&quot; screentip=&quot;My Button Screentip&quot; onAction=&quot;OnToggleButton1&quot; imageMso=&quot;AccessFormModalDialog&quot; /> </group> </tab> </tabs> </ribbon> </customUI> For example:
    10. 11. Ribbon Customization <ul><li>Office built-in support for XML-based customization model </li></ul><ul><li>VSTO 2005 SE support </li></ul><ul><ul><li>Simplifies hookup from .NET via pre-generated classes and sample XML </li></ul></ul><ul><li>VSTO v3.0 (Visual Studio 2008) support </li></ul><ul><ul><li>Adds full-blown visual designer support </li></ul></ul><ul><ul><li>“ Export to XML” option </li></ul></ul><ul><ul><li>A more robust programming layer inc. events </li></ul></ul>
    11. 12. Ribbon Designer Property Grid Ribbon Control Toolbox Design Surface
    12. 13. Custom Task & Actions Panes <ul><li>VSTO simplifies and speeds up task pane UI design process with visual designers and .NET hookup </li></ul><ul><ul><li>Actions Pane </li></ul></ul><ul><ul><ul><li>More robust, easier to program alternative to Office’s built-in “Smart Document” technology </li></ul></ul></ul><ul><ul><li>Custom Task Pane </li></ul></ul><ul><ul><ul><li>The same general idea as Actions Pane, only on the application add-in level, not individual doc </li></ul></ul></ul>
    13. 14. Pane UI Customization
    14. 15. Custom Task Panes and Action Panes
    15. 16. ActionsPane Architecture Document Actions Task Pane WinForms UserControl (ActionsPane) VSTO Invisible ActiveX Control
    16. 17. Outlook Form Region Features <ul><li>New technology in Outlook 2007 for enhancing and replacing Outlook’s built-in forms </li></ul><ul><li>Code behind form region is implemented as COM add-in </li></ul><ul><li>New controls provide built-in look & feel and data binding to Outlook data </li></ul>
    17. 18. 4 Types of Form Regions <ul><li>Adjoining and Separate </li></ul><ul><ul><li>Custom and built-in forms </li></ul></ul><ul><li>Replacement and Replace-all </li></ul><ul><ul><li>Custom forms only </li></ul></ul><ul><li>Reading Pane can display all types except Separate </li></ul>
    18. 19. Adjoining in Reading Pane
    19. 20. Adjoining in Inspector
    20. 21. Separate
    21. 22. Replacement & Replace-All
    22. 23. VS2008 Outlook Form Regions <ul><li>VSTO eases development of Outlook form regions </li></ul><ul><ul><li>Configure form region with a simple, intuitive wizard </li></ul></ul><ul><ul><li>Debugging (F5), Intellisense </li></ul></ul><ul><li>Import </li></ul><ul><ul><li>Use wizard to import Outlook-created OFS file </li></ul></ul><ul><ul><li>Controls are referenced & cast to correct name & type </li></ul></ul><ul><li>Design </li></ul><ul><ul><li>Designer supports WPF and Windows Form controls </li></ul></ul><ul><ul><li>Properties window exposes manifest </li></ul></ul>
    23. 24. Outlook Form Region
    24. 25. Fluent UI
    25. 26. Word Content Controls
    26. 27. Word Content Controls <ul><li>New experience for developing structured documents in Word 2007 </li></ul><ul><li>New UI for developers to access Word Content Controls </li></ul><ul><li>Programmable through Word Object Model </li></ul><ul><li>Support for XML Mapping </li></ul>
    27. 28. Toolbox Support <ul><li>Word content controls available in Toolbox </li></ul><ul><li>Increases discoverability of content controls </li></ul><ul><li>Drag-and-drop experience </li></ul>
    28. 29. Property Grid Support <ul><li>Easily access the properties and events of the content controls </li></ul>
    29. 30. Programming Paradigm <ul><li>Windows Forms style programming model </li></ul><ul><ul><li>Generate event handlers </li></ul></ul><ul><ul><li>Support for IntelliSense </li></ul></ul>
    30. 31. Word Content Controls
    31. 32. Two-Way Simple Data Binding <ul><li>Two methods to data bind </li></ul><ul><ul><li>Drag and drop support from Data Sources window </li></ul></ul><ul><ul><li>Set up through the property grid </li></ul></ul>
    32. 33. UI Feature Availability VSTO 2005 + VSTO 2005 SE VSTO v3.0 Ribbon (2007 versions of Word, Excel, Outlook and PowerPoint ) Simplified hookup Sample XML Simplified hookup Sample XML Visual designer Richer programming layer Export-to-XML option Actions Pane (document-level projects only) Word 2003 (doc, dot) Excel 2003 (xls, xlt) Word 2003 (doc, dot) Excel 2003 (xls, xlt) Word 2007 (docx/m, dotx/m) Excel 2007 (xlsx/m, xltx/m) Custom Task Pane (2007 versions of Word, Excel, Outlook, InfoPath and PowerPoint) Simplified hookup Visual designer Simplified hookup Visual designer Outlook Form Region (Outlook 2007 only) Visual designer Configuration wizard Import from existing Word Content Controls Drag n drop controls Simple data-binding Lock controls and content
    33. 34. Where we’ve been, what’s left <ul><li>VSTO Overview </li></ul><ul><li>Office Ribbon Designer </li></ul><ul><li>Custom Task Pane </li></ul><ul><li>Action Pane </li></ul><ul><li>Outlook Form Region Designer </li></ul><ul><li>Word Content Controls </li></ul><ul><li>VBA <-> VSTO interop </li></ul><ul><li>ClickOnce Deployment </li></ul>
    34. 35. Call VSTO from VBA <ul><li>You enable VBA via COM Interop </li></ul><ul><li>Interop implemented at design time </li></ul><ul><li>You can then call VSTO from VBA with IntelliSense after building the project </li></ul>
    35. 36. VBA and VSTO Interop
    36. 37. ClickOnce for Office Add-ins <ul><li>Low-impact deployment mechanism </li></ul><ul><ul><li>Self-contained </li></ul></ul><ul><ul><li>Solutions installed per user </li></ul></ul><ul><li>Prerequisites are installed if the user is an admin </li></ul><ul><li>ClickOnce support </li></ul><ul><ul><li>Full end-to-end solution installation </li></ul></ul><ul><ul><li>Richer version-independent security model </li></ul></ul><ul><ul><li>Offline access via the ClickOnce Cache </li></ul></ul>
    37. 38. ClickOnce Deployment
    38. 39. Summary <ul><li>The rationale for the VSTO architecture </li></ul><ul><ul><li>Bring together Office and .NET </li></ul></ul><ul><ul><li>Provide a sophisticated developer experience </li></ul></ul><ul><ul><li>Provide a solid baseline runtime infrastructure </li></ul></ul><ul><li>Office is a true development platform </li></ul>
    39. 40. MSDN in the UK <ul><li>Visit http://msdn.co.uk </li></ul><ul><ul><li>Newsletter </li></ul></ul><ul><ul><li>Events </li></ul></ul><ul><ul><li>Screencasts </li></ul></ul><ul><ul><li>Blogs </li></ul></ul>
    40. 41. Resources <ul><li>Visit the VSTO Developer Center </li></ul><ul><li>http://msdn.microsoft.com/office/tool/vsto/default.aspx </li></ul><ul><li>VSTO Help documentation on MSDN </li></ul><ul><li>http://msdn2.microsoft.com/en-gb/library/d2tx7z6d(vs.90).aspx </li></ul><ul><li>VSTO Forum </li></ul><ul><li>http://forums.microsoft.com/msdn/ShowForum.aspx?ForumID=16 </li></ul><ul><li>VSTO Team Blog </li></ul><ul><li>http://blogs.msdn.com/vsto2 </li></ul>
    41. 42. VSTO Design-Time Stack Visual Studio Project Templates IDE Hosting Item Wizards Workflow Document Solutions Add-ins Ribbons Form Regions SharePoint Excel, Word, Info Path Excel, InfoPath, Outlook, PowerPoint, Visio, Word, Project Excel, Outlook, PowerPoint, Word Outlook Separate IDE Info Path
    42. 43. VSTO/A Runtime Stack VSTO Runtime Office Client Host Managed/ Unmanaged Host Doc Task Pane Host Item Controls Win Forms Controls Doc-Level Solution App-Level Add-in Custom Ribbon Custom Task Pane Custom Form Region App-Level Add-in VSTA Integration Common VSTO/A Runtime .NET CLR Managed Add-in Framework (MAF) AppDomain Management Deployment and Updating Security Enforcement Doc-Level Solution ClickOnce

    ×