check box on continuous form

G

Guest

Hello, I am pretty new to Access 2003. I have linked several databases to one
central database. It is used to track tools. When you request a tool from the
several side, it shows as a request on the central side with a project
number. The person who maintains the tools will then check the "out" checkbox
to complete the transaction and transfer the project number to the location
box. The problem is that he also has the option to check out tools using a
combo box instead of a request. I cannot make this happen. Please look at my
code and tell me what I am doing wrong. Thanks so much in advance.

Private Sub OUT_Click()
If IsNull(Me.ComboLocation) Then
MsgBox "Please Select a Location", vbOKOnly, "Select Location"
Cancel = True
Me.Undo
ElseIf Me.ComboLocation = "By Request" And Not IsNumeric(Me.RequestJobNo) Then
MsgBox "There Is No Request For That Tool", vbOKOnly, "No Request"
Cancel = True
Me.Undo
ElseIf Me!ComboLocation = "By Request" And Me!OUT = True And Not
IsNull(Me!RequestJobNo) Then
Me.DateOut = Date
Me.DateIn = ""
Me.IN = False
Me.Location = Me.RequestJobNo
Me.DateOut.SetFocus
ElseIf Me.OUT = True And Me.ComboLocation <> "By Request" Then
Me.DateOut = Date
Me.DateIn = ""
Me.IN = False
Me.Location = Me.ComboLocation
Me.DateOut.SetFocus
Else
Me.DateOut = ""
Me.DateIn = Date
Me.Location = "Shop"
Me.IN = True
Me.DateIn.SetFocus
End If

End Sub
 
M

MacDermott

Perhaps you could tell us
What your code is doing that you don't want.
What your code isn't doing that you do want.
 
G

Guest

MacDermott,
Thanks for replying. I figured it out. I couldn't get past verifying
"RequestJobNo" field. It would either be empty or have a four digit number in
it. I used the "Len" function to verify the results.
Thanks Again
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top