Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Code works in XL2000 but not in XP!?

Please can anybody help?......and thanks in advance for looking.

I'm using the code below on a number input macro to check to see if th
number entered is the same as the validation code in hidden sheet1!A1

It works perfectly in Excel 2000 but a user reports that in Excel XP h
gets the message: "Compile error in module 2". When I looked at it i
appears that the problem is at the point of 'MyNum' in the 6th row.

I'm lost as to why it works in the earlier version but not in XP. Ca
anyone please suggest an answer?

Thanks!
-------------------------------------------------------------

Sub InputNumber()
Application.ScreenUpdating = False
Application.EnableCancelKey = xlDisabled
Sheets("Sheet1").Visible = True
Sheets("Sheet1").Select
myNum = InputBox("Please enter your 8 digit validation code. If yo
don't know it please contact XXXX", "Box Title")
If myNum = "" Then
Sheets("Sheet1").Visible = False
Sheets("Setup Sheet").Select
Application.ScreenUpdating = True
Exit Sub
End If
Range("A1").Value = myNum
Sheets("Sheet1").Visible = xlSheetVeryHidden

Sheets("Setup Sheet").Select
Application.ScreenUpdating = True
End Sub
------------------------------------------------------------

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

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,718
Default Code works in XL2000 but not in XP!?

Ask the user to check Tools, References in the VBE when your app is active.
Something will likely be labeled "missing".

--
Jim Rech
Excel MVP


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Code works in XL2000 but not in XP!?

You're right!

It says "MISSING: OCWebPreview ActiveX Control Module".

This needs to be usable by anyone with XL2000 or later. Can you
(anyone) suggest a work-around that would enable this to happen?

How can I overcome this even on a single PC?

Can I get an auto-open macro to make whatever changes are required to
make it work or should I look for an alternative code that won't cause
this to happen?

Thanks for your help.

Regards,


---
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
code works - need to save Ted Roche Excel Discussion (Misc queries) 1 January 7th 09 06:08 PM
How do I convert works file to excel without works software? CatMB Excel Discussion (Misc queries) 1 June 21st 05 04:12 PM
FILTERRING XL2000 Tom Ogilvy Excel Programming 0 August 30th 03 06:12 PM
XL2000 VBA code to ACCESS 2000 Tom Rudski Excel Programming 1 August 20th 03 08:41 AM
VBA Code Works in 97, Not in 2002 William[_2_] Excel Programming 11 August 12th 03 02:05 AM


All times are GMT +1. The time now is 08:47 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"