compguru910
Well-known member
- Joined
- Nov 25, 2009
- Messages
- 47
- Programming Experience
- 3-5
I seem to be running into an issue. This may seem like a noob question (which it really is, I only have experience in vb6 from years ago) but what Im trying to do is pass a variable from one form to another. Ive tried telling the first form to set the value of the variable on the second form like so frmsecond.variable = "value" but that does not work. Ive tried placing a public variable in a module to do it, but again, no luck. The only way seem to be able to get it to work is the second form setting the variable by reading the value from the first form like so
strVariable = frmfirst.datagridview.Rows(1).Items(1).Value (or something to that effect, im not sitting in front of the code)
The problem I have with that code is what if for some reason the selected line gets changed as the form is loading or something to that nature. It doesnt seem very secure. Any help would be appreciated.
strVariable = frmfirst.datagridview.Rows(1).Items(1).Value (or something to that effect, im not sitting in front of the code)
The problem I have with that code is what if for some reason the selected line gets changed as the form is loading or something to that nature. It doesnt seem very secure. Any help would be appreciated.