B
Bazza
Hiya,
New to VB.NET so this is probably a fairly easy solution(?!?!)
I have an application which currently uses singleton forms. Great -
everything worked fine except the users now want the ability to open
mulitple records.
So scenerio is I have a main parent form which has a text box for
customer number. After entering the number a new form appears which
contains the customer information. Now what I want is they can enter
another customer number which then opens another customer form with
the new customer info. This I have achieved. The problem I have is I
use classes to hold the cust info since they can go to sub forms from
the main form (saves passing params all over the place).
So ParentForm calls Form1 and then ParentForm calls Form1 again (so
both Form1's are displayed but with different customer info). When I
get the focus of one of the customer forms my class remembers the last
customer form open.
How do I when getting the focus for the whichever customer form also
gets the correct customer form class data.
I would have thought that creating a new customer class when each new
form is opened would be for that form only but this seems not to be
the case.
FYI - Visual Studio 2005 VB.NET
Thanks in advance
Bazza
New to VB.NET so this is probably a fairly easy solution(?!?!)
I have an application which currently uses singleton forms. Great -
everything worked fine except the users now want the ability to open
mulitple records.
So scenerio is I have a main parent form which has a text box for
customer number. After entering the number a new form appears which
contains the customer information. Now what I want is they can enter
another customer number which then opens another customer form with
the new customer info. This I have achieved. The problem I have is I
use classes to hold the cust info since they can go to sub forms from
the main form (saves passing params all over the place).
So ParentForm calls Form1 and then ParentForm calls Form1 again (so
both Form1's are displayed but with different customer info). When I
get the focus of one of the customer forms my class remembers the last
customer form open.
How do I when getting the focus for the whichever customer form also
gets the correct customer form class data.
I would have thought that creating a new customer class when each new
form is opened would be for that form only but this seems not to be
the case.
FYI - Visual Studio 2005 VB.NET
Thanks in advance
Bazza