How can I test in VBA what edition of Office a user is running

G

Guest

Using Excel 2003 I created a spreadsheet using XML import and export. The
help information says the following on the XML features in Excel 2003:

* Note XML features, except for saving files in the XML Spreadsheet
format, are available only in Microsoft Office Professional Edition 2003 and
Microsoft Office Excel 2003.

I'd want to inform the user whether the XML features will work or not.
Using "Application.Version" I get the Excel version.

Does anyone know how to test the office edition in VBA?
 
B

Bob Phillips

If val(application.Version)>10 Then
MsgBox "XML works"
End If

--
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)
 
G

Guest

In a post from Michel Pierron I read about the property
Application.ArbitraryXMLSupportAvailable

This will tell me what I need to know. Thank you Michel!
 
G

Guest

At home I have Microsoft Office Excel 2003 (so version 11.0) and Microsoft
Office Basic Edition. Your code will not work for this situation.

Thanks anyway for your reply Bob.
 
B

Bob Phillips

Why not? It tests for > 10, and guess what, 11 is > 10.

--
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)
 
B

Bob Phillips

But that errors in 2002 and before.

--
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top