I have my main form called frmApplicantDetail and on it is a subform called sfrmCommunitySelect.
The subform sfrmCommunitySelect is comprised of the following fields from the table tblCommunitySelect:
CommunitySelectID - PK
ApplicantID - Applicant ID
SelectTypeID - Lookup into the tlkpSelectType table (a dropdown list on the subform)
CommunityID - Lookup to the tlkpCommunity table (a dropdown list on the subform)
Back on the mainform I have a textbox called txtFirstSelectionCount in which I would like to populate with the number of selection already in the system based on what is selected in the subform. I have query written that counts the selection already called CommunitySelectionCount:
SELECT Count(tblCommunitiesSelected.CommunitiesID) AS CountOfCommunitiesID, tlkpCommunity.CommunityName, tlkpSelectionType.SelectionTypeName, tblApplication.IsCurrent
FROM ((tblCommunitiesSelected LEFT JOIN tlkpCommunity ON tblCommunitiesSelected.CommunityID = tlkpCommunity.CommunityID) LEFT JOIN tlkpSelectionType ON tblCommunitiesSelected.SelectionTypeID = tlkpSelectionType.SelectionTypeID) INNER JOIN tblApplication ON tblCommunitiesSelected.ApplicationID = tblApplication.ApplicationID
GROUP BY tlkpCommunity.CommunityName, tlkpSelectionType.SelectionTypeName, tblApplication.IsCurrent
HAVING (((tblApplication.IsCurrent)=True));
Now the scenario - The user select First from the SelectionType field in the subform and then selects Eagle Butte from the Community field in the subform. Based on that selection I want to return to the textbox on the main form "First Selection Eagle Butte 645 selections" or something of that nature.
Any ideas?
Thank you
Art Lorenzini
Sioux Falls, SD
Posted by: dbalorenzini@yahoo.com
Reply via web post | • | Reply to sender | • | Reply to group | • | Start a New Topic | • | Messages in this topic (1) |
Tidak ada komentar:
Posting Komentar