Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Macro works fine in xl2002 but does not in xl 2000

Hi!
The following code work fine in xl2002 but wont work in xl2000.
I have 2 buttons that run the following code, could someone take a loo
and tell me why it does not work.

Thanks for your help,
Nolin


Private Sub btnHide_Click()
On Error Resume Next
Application.ActiveWorkbook.Unprotect
Application.ActiveSheet.Unprotect
Application.ScreenUpdating = False
Worksheets("Purchase").ScrollArea = ("a1:i60")
Worksheets("Purchase").Range("f24:i29").Cut
Worksheets("Purchase").Paste Destination:=Worksheet
_("Purchase").Range("f54:i59")
Worksheets("Purchase").Range("f24:i29").Select
Selection.Interior.Color = RGB(223, 223, 232)
Worksheets("Purchase").Range("d10").Select
Worksheets("Purchase").btnHide.Visible = False
Worksheets("Purchase").btnShow.Visible = True
Worksheets("Purchase").Image4.Visible = True
Worksheets("Purchase").ScrollArea = ("a1:i29")
Application.ScreenUpdating = True
Application.ActiveSheet.Protect
Application.ActiveWorkbook.Protect

End Sub

Private Sub btnShow_Click()
Application.ActiveWorkbook.Unprotect
Application.ActiveSheet.Unprotect
Application.ScreenUpdating = False
Worksheets("Purchase").ScrollArea = ("a1:i60")
Worksheets("Purchase").Range("f54:i59").Cut
Worksheets("Purchase").Paste Destination:=Worksheet
_("Purchase").Range("f24:i29")
Worksheets("Purchase").Range("g25").Select
Worksheets("Purchase").btnShow.Visible = False
Worksheets("Purchase").btnHide.Visible = True
Worksheets("Purchase").Image4.Visible = False
Worksheets("Purchase").ScrollArea = ("a1:i29")
Application.ScreenUpdating = True
Application.ActiveSheet.Protect
Application.ActiveWorkbook.Protect

End Su

--
Message posted from http://www.ExcelForum.com

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Macro works fine in xl2002 but does not in xl 2000

Nolin,

I too am having trouble getting code written in XL 2002 to work whe
run on XL 2000. One issue I noticed, however, is that if the user o
XL2000 has kept their XL updated with service packs, then the macro
work. I don't know what service pack fixs the problem though.

Another suggestion: Trap the line in your code that is causing th
hangup and post the error on these pages. I do this by inserting:

msgbox ("A")
1st line of code
msgbox("B")
2ndline of text

etc. When the macro runs on XL2000 you can find which line causes th
problem


I have another post out there where I ask the similar question and I a
asking for some feedback. Use search option on this forum fo
username: "jasonsweeney" and see my related post

--
Message posted from http://www.ExcelForum.com

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
xls file works fine in Excel 2000 and 2007 but crashes on opening in 2003 gromit12 Excel Discussion (Misc queries) 2 November 6th 07 09:30 PM
Pivot table is not valid in Excel 2000 but works fine in EXCEL 200 Ulrik Loves Horses Excel Discussion (Misc queries) 1 December 18th 06 03:08 PM
Macro fine Run fine from Select but not from KB Shortcut? [email protected] Excel Discussion (Misc queries) 8 August 31st 06 02:06 AM
Macro hangs up often but sometimes works fine Jeff Excel Worksheet Functions 3 June 13th 06 01:01 PM
VLOOKUP on separate file: Works fine for a while.... Ken Cobler Excel Worksheet Functions 0 September 16th 05 05:18 PM


All times are GMT +1. The time now is 11:24 AM.

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"