Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

required set of records? before save

Status
Not open for further replies.
Jun 1, 2006
9
PH
hi everyone im a new in access design, i would like know on how i can get this workout in to code. this my scenario. i have a mainform with a two subform linking to mainform. here is the full details of my table and explanation?

tblCrewList
IDCRWLIST (Autonumber)PKey
Position (text) combo that link to tblRank (Intermediate) to Rank

tblCREWLIC
IDCREWLIC (autoNumber)PKey
IDCRWLIST (Number) Link in tblCrewList (1-M relationship)
IDLICENSE (Number) Link in tblLICENSE (Intermediate) Combobox

tblLICENSE
IDLICENSE (AutoNumber)PKey
LINCENSENAME (Text)

tblRANK
IDRANK (autoNumber)Pkey
RANK (Text) Name of the Position

required
IDLICENSE (Number) Link to tblLICENSE
RANK (text) Link to tblRANK (Intermediate)

then i made a mainform as recordsource is tblCrewList with
field textbox
IDCRWLIST
POSITION (Combobox that link in tblRANK,Rank)

then a subform 1 withrecordsource is tblCREWLIC with field textbox
IDCREWLIC (autoNumber)PKey
IDCRWLIST (that link in tblCrewList) and Child & Master
IDLICENSE (Number) Link in tblLICENSE Combobox

then subform 2 with recordsource is table required
IDLICENSE (Number) Combobox
RANK (text) Combobox
i just filled this subform with corresponding data like
IDLICENSE RANK
PRC CAPTAIN
GOC CAPTAIN
SIRB CAPTAIN
TESDA BOSUN
SIRB BOSUN
GOC BOSUN
and so on

so when i open the mainform the subform 2 will auto fill w/ the
corresponding data when a position is filled in mainform while the subform 1 is not filled with data. so the user manually filled the subform 1 with regards the position of required licensename. so when they try to save the whole mainform it will prompt then some message that it will required some data that matches in subform 2. if all data are match in subform 2 it will save but if not the missing IDLICENSE will prompt them in message saying "you can't save unless a required "the IDLICENSE" is entered in subform 1.

hoping for your kind help to. thanks
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top