By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
464,726 Members | 1,105 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 464,726 IT Pros & Developers. It's quick & easy.

Form variable

P: n/a
In my form I have several buttons that use the same string value. So I would
like to assign a constant that is global for the form. What's the best way
to do this? In which section do I place this constant code?
Thanks,
john
Jun 13 '07 #1
Share this Question
Share on Google+
2 Replies

P: n/a
Declare the constant at the top of the form, in the declarations section.
That will make it a module-level constant. I usually prefix my module level
variables and constants with an "m" to differentiate them from local ones.
Thus, I would do something like:

Const mconMyString = "Some string"

Neil

"John" <jo@hn.comwrote in message news:f4**********@textnews.wanadoo.nl...
In my form I have several buttons that use the same string value. So I
would like to assign a constant that is global for the form. What's the
best way to do this? In which section do I place this constant code?
Thanks,
john

Jun 13 '07 #2

P: n/a
Thank you.
john

"Neil" <no****@nospam.netschreef in bericht
news:Rg******************@newssvr14.news.prodigy.n et...
Declare the constant at the top of the form, in the declarations section.
That will make it a module-level constant. I usually prefix my module
level variables and constants with an "m" to differentiate them from local
ones. Thus, I would do something like:

Const mconMyString = "Some string"

Neil

"John" <jo@hn.comwrote in message
news:f4**********@textnews.wanadoo.nl...
>In my form I have several buttons that use the same string value. So I
would like to assign a constant that is global for the form. What's the
best way to do this? In which section do I place this constant code?
Thanks,
john


Jun 13 '07 #3

This discussion thread is closed

Replies have been disabled for this discussion.