T
TotallyConfused
ave a main from and subform (frm 1). My main form holds docs names, my
subform (frm2) lists pts with doc on my form. From within my subform I call
another form (frm3) to be able to add dates for specific pt. In my “frm3â€,
I have ID, doc ID and pt ID and fields for 3 dates: Send Date, Due Date,
Response Date. I would like for my “frm3†to be able to add another row of
Dates for that specific pt ID. What my form is doing now is when I click on
the “new date button†it will move to “Record 2†and the Date fields are
blank which good for the Date fields to be blank but the ID, doc ID and pt ID
are blank also. I want to maintain the ID, DOC ID and PT id when adding new
date fields for the specific record. I also would like the dates to be added
right below the first set of dates. Can this be done and so how. Can
someome please help me with this as this is driving me crazy. Thank you very
much in advance for any help you can provide. Attached is my code for the
command button “frm2†that calls “frm 3â€.
Private Sub cmdtrkdts_Click()
On Error GoTo Err_cmdtrkdts_Click
Dim stDocName As String
Dim stLinkCriteria As String
stDocName = "PTTRKDTs"
stLinkCriteria = "[DOCID]=" & Me![DOCID]
DoCmd.OpenForm stDocName, , , stLinkCriteria
Exit_cmdtrkgfxs_Click:
Exit Sub
Err_cmdtrkdts_Click:
MsgBox Err.Description
Resume Exit_cmdtrkgfxs_Click
subform (frm2) lists pts with doc on my form. From within my subform I call
another form (frm3) to be able to add dates for specific pt. In my “frm3â€,
I have ID, doc ID and pt ID and fields for 3 dates: Send Date, Due Date,
Response Date. I would like for my “frm3†to be able to add another row of
Dates for that specific pt ID. What my form is doing now is when I click on
the “new date button†it will move to “Record 2†and the Date fields are
blank which good for the Date fields to be blank but the ID, doc ID and pt ID
are blank also. I want to maintain the ID, DOC ID and PT id when adding new
date fields for the specific record. I also would like the dates to be added
right below the first set of dates. Can this be done and so how. Can
someome please help me with this as this is driving me crazy. Thank you very
much in advance for any help you can provide. Attached is my code for the
command button “frm2†that calls “frm 3â€.
Private Sub cmdtrkdts_Click()
On Error GoTo Err_cmdtrkdts_Click
Dim stDocName As String
Dim stLinkCriteria As String
stDocName = "PTTRKDTs"
stLinkCriteria = "[DOCID]=" & Me![DOCID]
DoCmd.OpenForm stDocName, , , stLinkCriteria
Exit_cmdtrkgfxs_Click:
Exit Sub
Err_cmdtrkdts_Click:
MsgBox Err.Description
Resume Exit_cmdtrkgfxs_Click