LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 34
Default declaring Arrays to use in a Form with few modules

How can I declare an Array in a form that will function as "Public". Those
arrays values can be updated for every modules that is called when this form
runs.?

I have an example:

This array will be like:

ReDim ErrorValue(1 To Len(myVal)) As String

*I need it PUBLIC because those array values are going to be updated in each
of the following functions:

function check4code1()
€¦
frmCheckCells.ErrorValue(k) ="Type 1" 'for check4code1
€¦
end function


function check4code2()
€¦
frmCheckCells.ErrorValue(k) ="Type 2" 'for check4code2
€¦
end function

€¦.and More functions€¦.


if no error is found then ErrorValue will be €œ€

Then, at the end of the process. The form will have a result like this

Sub searchX()
€¦
lbltxtErrorFound=ErrorValue(0) + ErrorValue(1) +ErrorValue(2)€¦€¦
€¦.

End sub


Can it be the best option ?

Thanks

Coco

 
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
Basic question - modules and class modules - what's the difference? Mark Stephens[_3_] Excel Programming 9 May 8th 05 11:48 AM
When to code in sheet or userform modules and when to use modules Tony James Excel Programming 1 December 16th 04 10:02 PM
Declaring arrays Alan Beban[_2_] Excel Programming 22 May 12th 04 08:10 AM
Class Modules vs Modules Jeff Marshall Excel Programming 2 September 28th 03 07:57 PM
Scope of variable includes all Form _and_ Code modules?? John Wirt[_2_] Excel Programming 5 August 18th 03 08:27 AM


All times are GMT +1. The time now is 09:49 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"