-
Program help!
Hey im writing a small prgam, however im a little stuck. One of the forms im writing displays a kids price and an adults price, as well as this the user can input how many kids or adults item /she needs. The problem is that the cost of the items needs to be carried across to another form where extra items can be added thus adding more to the price. How can i send the total to the next page where it becomes the grand total?
-
Re: Program help!
-
Re: Program help!
Are you talking about VB forms or web forms?
In VB any control can be queried on any form by preceding the control's name with the form name.
Example from Form2: Form1.Text1.Text = "Hello World"
-
Re: Program help!
Or, you can store the Total using a Global/Public variable. So, that, you will be able to access it from anywhere in the program...
For declaring a Global/Public variable, declare the variable inside a Module, using a Public keyword.
Example(inside Module1):
Code:
Public intTotal as Integer
... :wave: