Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 41
Default project wide compconditional compile constants

The docs mention that it is possible to define
compiler constants for a whole project, not just for one module.
I could not find how this can be done.
Can anybody tell me?

Erich Neuwirth
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 244
Default project wide compconditional compile constants

at the top of a Module put in something like this
Public Const MyConst As String = "MyString"
  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 811
Default project wide compconditional compile constants

"Erich Neuwirth" wrote in message
...
The docs mention that it is possible to define
compiler constants for a whole project, not just for one module.
I could not find how this can be done.
Can anybody tell me?


Hi Erich,

From the VBE menu select Tools/<VBAProject Properties, where
<VBAProject is the actual name of your project. The bottom textbox on the
General tab allows you to define global conditional compilation constants.

--
Rob Bovey, MCSE, MCSD, Excel MVP
Application Professionals
http://www.appspro.com/

* Please post all replies to this newsgroup *
* I delete all unsolicited e-mail responses *



  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 41
Default project wide compconditional compile constants

#Const LocalExternalServer = True
is what I currently have in a module.
I would like to have this global,
but when I try to enter
LocalExternalServer = True
as described below,
it does not work.
I get
invalid syntax for constant declarations.

Are only integer constants allowed there?

Rob Bovey wrote:

"Erich Neuwirth" wrote in message
...

The docs mention that it is possible to define
compiler constants for a whole project, not just for one module.
I could not find how this can be done.
Can anybody tell me?



Hi Erich,

From the VBE menu select Tools/<VBAProject Properties, where
<VBAProject is the actual name of your project. The bottom textbox on the
General tab allows you to define global conditional compilation constants.

  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 811
Default project wide compconditional compile constants

"Erich Neuwirth" wrote in message
...
#Const LocalExternalServer = True
is what I currently have in a module.
I would like to have this global,
but when I try to enter
LocalExternalServer = True
as described below,
it does not work.
I get
invalid syntax for constant declarations.

Are only integer constants allowed there?


Hi Erich,

Yes, that's correct. Sorry I forgot to mention it. Zero = False and
non-zero = True. You can define multiple constants by using a colon as a
separator.

--
Rob Bovey, MCSE, MCSD, Excel MVP
Application Professionals
http://www.appspro.com/

* Please post all replies to this newsgroup *
* I delete all unsolicited e-mail responses *


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
Compile error: Can't find project or library Melanie New Users to Excel 14 August 21st 09 02:54 AM
help with this error-Compile error: cant find project or library JackR Excel Discussion (Misc queries) 2 June 10th 06 09:09 PM
Compile Error, Can'f Find Project or Library therrm Excel Programming 1 November 25th 03 04:53 AM
Compile Error! Can't find project or Library --- Help! Suh Suk Ho Excel Programming 2 July 21st 03 08:26 PM
Project won't compile... tritan Excel Programming 1 July 17th 03 05:37 PM


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