I feel that I am forever asking questions in this place and never able to help answer other peoples.
Alas:
I want to pass a variable from form 1 to form 2, the information that the variable is to contain is a customer number that a SQL statement has pulled out of a database for me.
Having searched for 2 hrs solid and only being able to pass a variable with nothing in it to the new form I have surrendered.
I need the code or a step by step to get it, please help, I'm on the edge.
Here's the code that I have already:
To retrieve the data (code in form 1)
To store variable in form 2:
followed by a sql insert statement later in the form.
Thanks in advanced for any help, and how long does it take to understand this stuff. I am still so lost its scary.
Graham
Alas:
I want to pass a variable from form 1 to form 2, the information that the variable is to contain is a customer number that a SQL statement has pulled out of a database for me.
Having searched for 2 hrs solid and only being able to pass a variable with nothing in it to the new form I have surrendered.
I need the code or a step by step to get it, please help, I'm on the edge.
Here's the code that I have already:
To retrieve the data (code in form 1)
VB.NET:
'retieves the customerID for next form
Dim da As New OleDb.OleDbDataAdapter("SELECT customerID from tblCustomer WHERE customerfirstname = firstname AND customersurname = surname AND postcode = postcode", connect)
Dim ds As New DataSet
da.Fill(ds)
Dim f2 As New bookingfrmPt1
f2.custID = da
VB.NET:
Public custID
Thanks in advanced for any help, and how long does it take to understand this stuff. I am still so lost its scary.
Graham