Cant get data into report

Gazza2

Registered User.
Local time
Today, 01:32
Joined
Nov 25, 2004
Messages
184
I have the following code in a forms textbox:

Private Sub Text29_AfterUpdate()
Select Case Me.Text29
Case "t"
DoCmd.GoToRecord , , acFirst
strWhere = "[jobno] =" & Me.JobNo
DoCmd.OpenReport "jobs", acViewPreview, , strWhere
DoCmd.Close acForm, "newjob"
Case "c"
DoCmd.SetWarnings False
DoCmd.RunCommand acCmdDeleteRecord
DoCmd.SetWarnings True
DoCmd.Close acForm, "newjob"

End Select

End Sub

The idea is that the user can enter a jobs details and then enter into the textbox "t" to preview the report before printing(at the moment to test if the data actually displays) or "c" to cancel the job. Most of the code works except the data doesnt display in the report.

Can anyone explain where it goes wrong

thanks
 

Users who are viewing this thread

Back
Top Bottom