ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   workbook dont run macro under a lower version (https://www.excelbanter.com/excel-programming/325509-workbook-dont-run-macro-under-lower-version.html)

kalz

workbook dont run macro under a lower version
 
Dear All,

Pls help tt,I have create a workbook with lox macro, and hav to hide them
from the end users, it was saved as "Microsoft Excel wookbook" type,(i.e. as
restricted from saving as a lower version workbook. However, problem is when
i try to open it under a lower version of MS-Office 2000, it promps me a run
time error msg and asking for debugging. The bugging line indicates a copy
and paste special section not able to run. On the other hand, if i choose to
End the debug, certainly no macro proceeded. If there any way to solve the
problem? or even, not to hide the macro but only the pre-definied password
inside macro ?

thx soso much!!

OJ[_2_]

workbook dont run macro under a lower version
 
Kalz,
sounds to me like you are using a paste method which was not available
in the earlier Excel version. Please post the code so that we can
identfy it for you.

OJ


kalz

workbook dont run macro under a lower version
 
Dear OJ,

This is the highlighted line:

Selection.copy
Range("AF4").Select
Range(Selection, Selection.End(xlDown)).Select
Selection.PasteSpecial Paste:=xlPasteValidation, Operation:=xlNone, _
SkipBlanks:=False, Transpose:=False

"OJ" wrote:

Kalz,
sounds to me like you are using a paste method which was not available
in the earlier Excel version. Please post the code so that we can
identfy it for you.

OJ



kalz

workbook dont run macro under a lower version
 
Code as followed:

Selection.copy
Range("AF4").Select
Range(Selection, Selection.End(xlDown)).Select
Selection.PasteSpecial Paste:=xlPasteValidation, Operation:=xlNone, _
SkipBlanks:=False, Transpose:=False


thx
"OJ" wrote:

Kalz,
sounds to me like you are using a paste method which was not available
in the earlier Excel version. Please post the code so that we can
identfy it for you.

OJ



OJ[_2_]

workbook dont run macro under a lower version
 
Hi Kalz,
I cannot confirm this but I would hazard a guess that xlPasteValidation
is not available in the earlier version of Excel. What happens when you
put the cursor over xlPasteValidation and hit F1 for help?

O



All times are GMT +1. The time now is 04:02 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com