Difference between revisions of "Referencing the Ribbon Commander library in VBA"

From Ribbon Commander Documentation
Jump to: navigation, search
 
Line 1: Line 1:
 
# Create a new project in your favourite office application
 
# Create a new project in your favourite office application
 
# Add a VBA reference to the Ribbon Commander library (Tools->References)
 
# Add a VBA reference to the Ribbon Commander library (Tools->References)
#: [[image:VBAReference.png]]
+
#: [[image:VBAReference_ILYDA_UK.png]]
 
# The library is now ready to use. In the immediate window enter  
 
# The library is now ready to use. In the immediate window enter  
 
#: <syntaxhighlight lang="vb">?rxCustomUI.defaultInstance.targetOfficeVersion</syntaxhighlight>
 
#: <syntaxhighlight lang="vb">?rxCustomUI.defaultInstance.targetOfficeVersion</syntaxhighlight>
 
#: This should print the major version of the office platform you are using. If you are running in an older version of office you will get a runtime error instead (the error message here is for excel)
 
#: This should print the major version of the office platform you are using. If you are running in an older version of office you will get a runtime error instead (the error message here is for excel)
 
#: [[image:UnsupportedExcelVersion.png]]
 
#: [[image:UnsupportedExcelVersion.png]]

Latest revision as of 09:43, 21 October 2013

  1. Create a new project in your favourite office application
  2. Add a VBA reference to the Ribbon Commander library (Tools->References)
    VBAReference ILYDA UK.png
  3. The library is now ready to use. In the immediate window enter
    ?rxCustomUI.defaultInstance.targetOfficeVersion
    This should print the major version of the office platform you are using. If you are running in an older version of office you will get a runtime error instead (the error message here is for excel)
    UnsupportedExcelVersion.png