slide1 l.
Download
Skip this Video
Loading SlideShow in 5 Seconds..
CD303 - The 2007 Microsoft Office System: Developer Model for the New User Interface PowerPoint Presentation
Download Presentation
CD303 - The 2007 Microsoft Office System: Developer Model for the New User Interface

Loading in 2 Seconds...

play fullscreen
1 / 47

CD303 - The 2007 Microsoft Office System: Developer Model for the New User Interface - PowerPoint PPT Presentation


  • 85 Views
  • Uploaded on

CD303 - The 2007 Microsoft Office System: Developer Model for the New User Interface. Savraj Dhanjal Program Manager Microsoft Corporation. Alex Mogilevsky Architect Microsoft Corporation. The New User Interface. Access, Excel, Outlook, PowerPoint, Word. Ribbon Extensibility - “RibbonX”.

loader
I am the owner, or an agent authorized to act on behalf of the owner, of the copyrighted work described.
capcha
Download Presentation

PowerPoint Slideshow about 'CD303 - The 2007 Microsoft Office System: Developer Model for the New User Interface' - nubia


An Image/Link below is provided (as is) to download presentation

Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author.While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server.


- - - - - - - - - - - - - - - - - - - - - - - - - - E N D - - - - - - - - - - - - - - - - - - - - - - - - - -
Presentation Transcript
cd303 the 2007 microsoft office system developer model for the new user interface

CD303 - The 2007 Microsoft Office System: Developer Model for the New User Interface

Savraj Dhanjal

Program Manager

Microsoft Corporation

Alex Mogilevsky

Architect

Microsoft Corporation

the new user interface
The New User Interface
  • Access, Excel, Outlook, PowerPoint, Word
ribbon extensibility ribbonx
Ribbon Extensibility - “RibbonX”
  • Developers can modify the Ribbon
  • For example: remove tabs, add a tab, add a group
agenda
Agenda
  • Existing solutions
  • RibbonX Details
  • Demos
  • Migrating existing solutions
  • Conclusion
  • Questions
agenda6
Agenda
  • Existing solutions
  • RibbonX Details
  • Demos
  • Migrating existing solutions
  • Conclusion
  • Questions
existing solutions
Existing Solutions
  • XLM
  • WordBasic
  • CommandBars (‘96)
  • WLL, XLL
  • XLA, PPA, Word global templates
  • In Excel, “Init Menus” registry key
  • Attached Toolbars in Word & Excel
  • Other technologies…
  • And it all still works!
existing solutions8
Existing Solutions

Custom Buttons

on Formatting Toolbar

Custom Menu

Custom Toolbars

agenda10
Agenda
  • Existing solutions
  • RibbonX Details
  • Demos
  • Migrating existing solutions
  • Conclusion
  • Questions
before office 2007
Before Office 2007…

Inconsistency across applications

Office 2000 VBA Programmers Guide, MS Press, 1999

before office 200712
Before Office 2007…
  • Hard to build well-behaved add-ins
  • Hard to reference built-in controls, images
  • Hard to localize
  • Nearly impossible to make add-in customizable by end users
  • Easy to have add-in conflicts
  • Result: UI deteriorates over time
ribbonx
RibbonX…
  • Is a consistent, XML-based developer model for Office UI
  • Produces well-behaved solutions by default
  • Exposes new control types
  • Targets specific developer scenarios
ribbonx basics
Add your own tabs

Add to built-in tabs

Add to the Office Menu

Add to built-in contextual tabs

Remove tabs, groups, controls

RibbonXBasics
ribbonx controls
Tabs

Groups

Buttons

Menus

SplitButtons

ToggleButtons

Labels

CheckBoxes

RibbonXControls
ribbonx controls19
EditBoxes

DialogBoxLaunchers

DropDowns

ComboBoxes

Galleries

RibbonX Controls

Only five controls in Office 2003:

msoControlButton, msoControlEdit,

msoControlPopup, msoControlComboBox,

msoControlDropdown

ribbonx markup
RibbonX Markup
  • Declarative XML
  • Easy to understand, localize, generate
  • Separates UI from your business logic
  • Gets applied to UI at add-in or document load

<tab idMso=“TabWrite”>

<group id=“myGroup” label=“My Group”>

<button id=“hw” label=“Hello World!”

onAction=“myHelloFunc” />

</group>

</tab>

ribbonx entry points
RibbonX Entry Points
  • New File Format Documents (VBA solutions)
    • Include customUI markup as a part
  • COM Add-Ins (C#, C++, VB.NET, VB6)
    • Return customUI markup via IRibbonExtensibility interface
  • VSTO v3 Solutions
    • Same as COM
    • Wizard, generated code (connection, resources, images)
    • GUI editor (maybe – see CD308 for VSTO pans)
ribbonx solution space
RibbonX Solution Space

COM

VBA

VSTO

(C#, VB.NET, VB6, C++)

Installed at app-level

Word: Global Template, Excel (.xlam)

PPT (.ppam)

contains

customUI part

VSTO v3

Write a VSTO v3 app-level solution

App.

Level

Word, Excel, PPT

New file format document

contains

customUI part

Access: loadCustomUI method

Installed at app-level, displays UI based on doc properties

VSTO v3

Write a VSTO v3 doc-based solution

Doc.

Level

ribbonx schema
RibbonX Schema
  • ribbon, tab, group, box
    • Containers
    • “Find or create” model
  • id, idMso
    • Define a custom id, refer to built-in id
  • insertAfterMso, insertBeforeMso
    • Insert in relation to built-in control
  • image, imageMso
    • Define your own image, refer to a built-in image
  • getImage, onAction, getEnabled, getVisible
    • Some of the available callbacks
hello world document

Hello World Document

Alex MogilevskyArchitect

Microsoft Corporation

features targeting developers
Features Targeting Developers
  • StartFromScratch
  • Global repurposing
  • Referencing built-in controls and images

<ribbon startFromScratch=“true”>

<!– hides the main tabs -->

<command idMso=“Save” onAction=“runMyCode” />

<!- takes over the built-in save action -->

<button id=“x” imageMso=“Save” label=“Imposter!” />

<!- “steals” the image of the Save button -->

dynamic update of controls
Dynamic Update of Controls
  • XML is the only way to add controls
    • No API to add new controls at arbitrary time
  • State and properties are dynamic, via callbacks
    • getVisible, getLabel, getImage…
  • Galleries, dynamicMenus
    • Can be dynamically populated with controls
  • The “pull” model
pull model
“Pull” Model
  • Questions you’ll never ask again
    • When is it OK to add UI? Remove?
    • In how many documents, windows?
    • Will I be called on uninstall to clean up?
    • Is there other code changing the same UI?
    • Can the user remove controls I want to change?
    • Can the user move or copy my controls?
  • No “housekeeping” code
    • No need to make adjustments at open, close, install, uninstall (unlike CommandBars)
outside scope of ribbonx
Status Bar

Mini Toolbar

Add/Remove inside built-in groups

Custom group scaling

Right-click (context) menus

However,

Existing right-click customizations work

Global repurposing works for all controls

Outside Scope Of RibbonX
agenda29
Agenda
  • Existing solutions
  • RibbonX Details
  • Demos
  • Migrating existing solutions
  • Conclusion
  • Questions
custom group tab gallery

Custom Group, Tab, & Gallery

Alex MogilevskyArchitect

Microsoft Corporation

custom office menu item

Custom Office Menu Item

Alex MogilevskyArchitect

Microsoft Corporation

dynamic update via invalidate
Dynamic Update via Invalidate

Call InvalidateorInvalidateControl

When Office updates the Ribbon, it will ask your code again for dynamic properties

Markup:

<button id=“MyButton” label=“My First Button”

getImage=“myButtonImage” />

C#:

Ribbon.InvalidateControl(“MyButton”);

Office queries your callback functions again.

invalidate

Invalidate

Alex MogilevskyArchitect

Microsoft Corporation

repurposing start from scratch

Repurposing, Start From Scratch

Alex MogilevskyArchitect

Microsoft Corporation

end user customization

End-User Customization

Alex MogilevskyArchitect

Microsoft Corporation

two excel workbooks

Two Excel Workbooks

Alex MogilevskyArchitect

Microsoft Corporation

outlook access

Outlook, Access

Alex MogilevskyArchitect

Microsoft Corporation

agenda38
Agenda
  • Existing solutions
  • RibbonX
  • Migrating existing solutions
  • Deployment
  • Conclusion
  • Questions
migrating a solution
Migrating a Solution
  • Spectrum of Possibilities

None

Don’t change your code whatsoever. Your added buttons appear on the add-ins tab.

Simple

Find the right place and the right control types for your UI in the new Ribbon. Just move them to the right place.

Full

Rethink your UI based on the new paradigms, perhaps using gallery controls and a reorganization of your commands.

simple migration
Simple Migration
  • In Office 2003, your code added items to the tools menu.
agenda43
Agenda
  • Existing solutions
  • RibbonX Details
  • Demos
  • Migrating existing solutions
  • Conclusion
  • Questions
conclusion
Conclusion…
  • Existing solutions still work
  • New model is XML-based, easier to build great add-ins
  • Optimized for common scenarios
  • Consistent across applications
  • You can spend your time building solutions, instead of worrying about the UI!
known changes at beta 2 tr
Known Changes at Beta 2 TR
  • <fileMenu> tag will be <officeMenu>
  • <advanced> tag will be <dialogBoxLauncher> in B2TR
  • Built-in control IDs will be significantly updated in B2TR
resources
Resources
  • Office Developer Center
    • http://msdn.microsoft.com/office/
  • Ribbon Developer Center
    • http://msdn.microsoft.com/office/tool/ribbon
  • UI Blog
    • http://blogs.msdn.com/jensenh/

see the developer section (Thursdays)

slide47

© 2006 Microsoft Corporation. All rights reserved.

This presentation is for informational purposes only. Microsoft makes no warranties, express or implied, in this summary.