Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsVB SyntaxEnterprise DevelopmentDatabase AccessControlsCOMWin APICrystal ReportDeploymentGeneralGeneral 2
Related Topics
VB.NET / ASP.NETMS SQL ServerMS AccessOther Database ProductsMore Topics ...

Re: Public variables in VB



Tip: Looking for answers? Try searching our database.



You are accessing this site in a read-only mode. For full access to all member benefits, including message posting, please login or register. Registration is completely free, simple, and takes only a few seconds.

Login | Free VBMonster.com registration | Whole discussion thread

The message you are replying to and its parents are listed in the reverse order with the most recent posts first. This might not be the whole discussion thread. To read all the messages in this thread please click here.

Re: Public variables in VB

Martin Trump28 May 2005 11:56
>TicketCost as Integer  ' 136.43

That looks strange to me.

Regards
Signature

Martin Trump


cricketunes@yahoo.com28 May 2005 01:02
Hi folks,
I am creating a Visual Basic application that uses 4 forms. I have a
list of data(2 types of cities) that I am storing into 2 arrays. Now
the contents of this array need to be shared across multiple forms.

I have two problems:

1) I tried to create a Public array in the Gen. Declaration section of
one of the forms, but it shouts a compile error and asks me not to make
arrays public. I really need the array data to be shared between
forms!! Which is the best place to put all the public variables.

2) I initially wanted to have a structure like this

Type CityInfo
CityName as String     'Atlanta
TicketCost as Integer  ' 136.43
End Type

and kept in the Module(.BAS file). When I tried to declare a public
variable in a form, it shouted out an error.

Any suggestions to overcome?

Thanks,
Cricket
[Newbie to VB]

Quick links:

 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage




©2010 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.