#1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 41
Default Weird error

I am getting the following error and I have no clue why:
Compiler error: Variable not defined

The error is showing up on:
Option Explicit
ScreenUpdating = False
(rest of the code deleted...)

What's the deal?

Thanks in advance,
Brad K
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 618
Default Weird error

Hi Brad

Application.ScreenUpdating = False

will work.

Cheers
JulieD

"Brad K." wrote in message
...
I am getting the following error and I have no clue why:
Compiler error: Variable not defined

The error is showing up on:
Option Explicit
ScreenUpdating = False
(rest of the code deleted...)

What's the deal?

Thanks in advance,
Brad K



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 43
Default Weird error

Brad K...
I am getting the following error and I have no clue why:
Compiler error: Variable not defined

The error is showing up on:
Option Explicit
ScreenUpdating = False
(rest of the code deleted...)

What's the deal?

Thanks in advance,
Brad K


Hi Brad,

Wild guess...

Option Explicit

Sub WildThang()

Application.ScreenUpdating = False

Rest of your code...


End Sub


  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11
Default Weird error

Brad,

You need to add "Application.(dot)" before S"creenUpdating = False"
See
Application.ScreenUpdating = False

And the code should be placed inside of a Sub like this.

Sub Test()
Application.ScreenUpdating = False
'Your Code Here
End Sub

--
Regards,
Colo
http://www.puremis.net/excel/

"Brad K." wrote in message
...
I am getting the following error and I have no clue why:
Compiler error: Variable not defined

The error is showing up on:
Option Explicit
ScreenUpdating = False
(rest of the code deleted...)

What's the deal?

Thanks in advance,
Brad K


  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 41
Default Weird error

Thanks all for the help. This did the trick.
Out of curiousity, why does one need to put "Application." in this instance.
Thanks,
Brad

"JulieD" wrote:

Hi Brad

Application.ScreenUpdating = False

will work.

Cheers
JulieD

"Brad K." wrote in message
...
I am getting the following error and I have no clue why:
Compiler error: Variable not defined

The error is showing up on:
Option Explicit
ScreenUpdating = False
(rest of the code deleted...)

What's the deal?

Thanks in advance,
Brad K






  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 618
Default Weird error

Hi Brad

don't know for sure (someone else around here probably will), but i'm
guessing that as you have Option Explicit you're making not only variable
declarations required but also ensuring that the objects are specified for
the methods or properties and not leaving it "to chance" (although help
doesn't say this!)

Regards
julieD

"Brad K." wrote in message
...
Thanks all for the help. This did the trick.
Out of curiousity, why does one need to put "Application." in this
instance.
Thanks,
Brad

"JulieD" wrote:

Hi Brad

Application.ScreenUpdating = False

will work.

Cheers
JulieD

"Brad K." wrote in message
...
I am getting the following error and I have no clue why:
Compiler error: Variable not defined

The error is showing up on:
Option Explicit
ScreenUpdating = False
(rest of the code deleted...)

What's the deal?

Thanks in advance,
Brad K






  #7   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,588
Default Weird error

ScreenUpdating is a property of the Application object, not the
workbook.
The Application has other properties such as Calculation etc.

Press F2 while in the VBE and you can browse the Application's
Properties and Methods

Tim



"Brad K." wrote in message
...
Thanks all for the help. This did the trick.
Out of curiousity, why does one need to put "Application." in this
instance.
Thanks,
Brad

"JulieD" wrote:

Hi Brad

Application.ScreenUpdating = False

will work.

Cheers
JulieD

"Brad K." wrote in message
...
I am getting the following error and I have no clue why:
Compiler error: Variable not defined

The error is showing up on:
Option Explicit
ScreenUpdating = False
(rest of the code deleted...)

What's the deal?

Thanks in advance,
Brad K






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
Weird Arithmetic Error Keith Excel Discussion (Misc queries) 7 February 7th 06 06:30 PM
Very weird error Stian Excel Worksheet Functions 4 November 21st 05 10:50 PM
Weird jhill New Users to Excel 1 August 10th 05 04:48 PM
vlookup weird error cutthroatjess Excel Worksheet Functions 3 June 17th 05 01:56 PM
Weird error messages Manuel Excel Discussion (Misc queries) 3 February 17th 05 04:45 PM


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