H
Hilary Ostrov
I have a form, myInvoice, on which I'm using a tabCtl with Pages
Jobsite, Details, Materials, Labour & Total.
PageJobsite has cboSiteID (and PageMaterials has cboSelectItem, both
of which are required fields LimitedToList). *Most* of the time, the
user will select a SiteID by the SiteID (rather than the JobsiteName,
also displayed in cboSiteID) and Materials by a Keyword (rather than
Mfg Code or Description both of which are also displayed in
cboSelectItem, along with other stuff), but there are exceptions
(currently covered off by NotInList, but it's not working as smoothly
as I'd like). So, to give the user greater flexibility at his
fingertips ...
I'd like to add to myInvoice form several unbound subs: AddJobsiteSub,
FindJobsiteSub, AddMaterialsSub and FindItemsSub (with initial
settings for all subs disabled and hidden, although I'm not sure if
both are necessary) any of which could be enabled and made visible via
a respective cmd button, but I'm not sure how many such unbound subs I
can include on one form.
My experiments to date have not been particularly successful. Via the
cmd Buttons I can display (e.g.) AddJobsiteSub then FindJobsiteSub or
vice versa, but don't know how to switch back. Assuming that this is
not an insurmountable obstacle, I'd like to incorporate the following.
For each NotInList (and/or cmd button):
a) suppress error msgs when I activate (I figured out the code to make
them visible!) either the AddJobsiteSub or FindJobsiteNameSub from
NotInList (or via cmd button); and
b) Exit AddJobsiteSub, reset the properties to disabled/not visible
(via cmd Button?), add the record to the source (or, in the case of
FindJobsiteNameSub, select the corresponding SiteID and then exit and
reset to disabled/hidden) in myInvoice.cboSiteID so the user can
continue on his merry way through the tabCtl.
Once I know how to do all this, I can then modify the code to do the
same for cboSelectItem - and/or any others that might be useful
elswhere in the application!
Or perhaps I'm not going about this the right way! In which case, any
suggested alternative approaches would be appreciated.
Thanks.
hro
Jobsite, Details, Materials, Labour & Total.
PageJobsite has cboSiteID (and PageMaterials has cboSelectItem, both
of which are required fields LimitedToList). *Most* of the time, the
user will select a SiteID by the SiteID (rather than the JobsiteName,
also displayed in cboSiteID) and Materials by a Keyword (rather than
Mfg Code or Description both of which are also displayed in
cboSelectItem, along with other stuff), but there are exceptions
(currently covered off by NotInList, but it's not working as smoothly
as I'd like). So, to give the user greater flexibility at his
fingertips ...
I'd like to add to myInvoice form several unbound subs: AddJobsiteSub,
FindJobsiteSub, AddMaterialsSub and FindItemsSub (with initial
settings for all subs disabled and hidden, although I'm not sure if
both are necessary) any of which could be enabled and made visible via
a respective cmd button, but I'm not sure how many such unbound subs I
can include on one form.
My experiments to date have not been particularly successful. Via the
cmd Buttons I can display (e.g.) AddJobsiteSub then FindJobsiteSub or
vice versa, but don't know how to switch back. Assuming that this is
not an insurmountable obstacle, I'd like to incorporate the following.
For each NotInList (and/or cmd button):
a) suppress error msgs when I activate (I figured out the code to make
them visible!) either the AddJobsiteSub or FindJobsiteNameSub from
NotInList (or via cmd button); and
b) Exit AddJobsiteSub, reset the properties to disabled/not visible
(via cmd Button?), add the record to the source (or, in the case of
FindJobsiteNameSub, select the corresponding SiteID and then exit and
reset to disabled/hidden) in myInvoice.cboSiteID so the user can
continue on his merry way through the tabCtl.
Once I know how to do all this, I can then modify the code to do the
same for cboSelectItem - and/or any others that might be useful
elswhere in the application!
Or perhaps I'm not going about this the right way! In which case, any
suggested alternative approaches would be appreciated.
Thanks.
hro