2003 to 2007 VBA ActiveX

wmstrand

New Member
Joined
May 28, 2010
Messages
1
I developed VBA macros in Excel 2007 that do not work in Excel 2003 - the Office CompatibilityPack is installed and the workbook is saved as .xls - I am using ActiveX CommandButtons - the "active.workbook." line of code is highlighted as in error, and will not compile - any thoughts would be appreciated . . .


ActiveWorkbook.Worksheets ("May 2010").Sort.SortFields.Clear
 
Last edited:

Some videos you may like

Excel Facts

Which Excel functions can ignore hidden rows?
The SUBTOTAL and AGGREGATE functions ignore hidden rows. AGGREGATE can also exclude error cells and more.

ZVI

MrExcel MVP
Joined
Apr 9, 2008
Messages
3,790
Office Version
  1. 2016
  2. 2010
  3. 2007
Platform
  1. Windows
SortField objects were added to Excel 2007.
It doesn't work in previous versions of Excel.
Sort ranges instead
 
Last edited:

Watch MrExcel Video

Forum statistics

Threads
1,118,168
Messages
5,570,605
Members
412,330
Latest member
carlosjw
Top