Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Version makes the difference?!


Hi everyone,

I encounter a problem with running macro in Excel. Basically all works
fine with Excel 2003(tested on 2 machines) whilst a run-time error
'1004' was fired on Excel 2000( failed on 2 machines). Apparently
there's somethiing wrong with compatibility issues between these 2
vesions. The detailed message says:

run-time error '1004':
The cell or chart you are trying to change is protected and therefore
read only.

That's true and used to prevent certain cells being modified by users.
But it does run smoothly on Excel 2003 without any problem.

The piece of code causing the problem:

Range(\"K10\").Select
'Macro halts on the next line
ActiveCell.Formula =
\"=SUMIF($D$26:$D$65536,\"\"POOL\"\",$M$26:$M$6553 6)\"

I need to make it work on both versions...Any idea of the solution?
All
kinds of help will be appreciated.

Thanks
Frank


--
uglyvb
------------------------------------------------------------------------
uglyvb's Profile: http://www.excelforum.com/member.php...o&userid=31720
View this thread: http://www.excelforum.com/showthread...hreadid=519542

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 107
Default Version makes the difference?!

Tthe workaround would be to add

ActiveSheet.UnProtect Password:="Whatever"
<Your Code
ActiveSheet.Protect Password:="Whatever"

but someone may have a 'real' answer!

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Version makes the difference?!


Thanks jakeyC for the nice workaround, which dismisses the runtime
error!...May I also refer you to
http://www.excelforum.com/showthread.php?t=519532, where a proper
solution has also been supplied?...

Regards
Frank


--
uglyvb
------------------------------------------------------------------------
uglyvb's Profile: http://www.excelforum.com/member.php...o&userid=31720
View this thread: http://www.excelforum.com/showthread...hreadid=519542

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How do I save an Excel 97-2003 version or 2007 version for Mac 200 Bronigal Excel Discussion (Misc queries) 1 December 7th 09 08:04 AM
Wrap Text: Print Version different than Screen Version sh2195 Excel Discussion (Misc queries) 0 August 25th 08 03:52 PM
Recover earlier version of excel sheet after new version saved? stephanie38 Excel Discussion (Misc queries) 3 June 17th 05 03:52 AM
Version difference when opening text files? Geoff C Excel Programming 3 March 22nd 05 02:24 PM
Difference in the listing of the New module addition in 2002 version Hari Excel Discussion (Misc queries) 2 January 4th 05 06:56 AM


All times are GMT +1. The time now is 07:22 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"