wizcow
Registered User.
- Local time
- Today, 01:55
- Joined
- Sep 22, 2001
- Messages
- 236
Hi
I am trying to use a posting routine from Acces97, in Access2000. But, it doesn't work.
It seems to hang up on the 'Dim Database'.
Public Function LookUpDescriptionAndPrice(tForm As Form, tItemNo As String)
DimtDB As Database, tTB As Table
Set tDB = CurrentDb()
Set tTB = tDB.OpenTable("Parts")
tTB.Index = "ItemNo"
tTB.Seek "=", tItemNo
tForm.Price = tTB.Cost
tForm.Description = tTB.Description
tTB.close
End Function
This is supost to post my Description and Cost fields.
Can anyone see the problem?
I am trying to use a posting routine from Acces97, in Access2000. But, it doesn't work.
It seems to hang up on the 'Dim Database'.
Public Function LookUpDescriptionAndPrice(tForm As Form, tItemNo As String)
DimtDB As Database, tTB As Table
Set tDB = CurrentDb()
Set tTB = tDB.OpenTable("Parts")
tTB.Index = "ItemNo"
tTB.Seek "=", tItemNo
tForm.Price = tTB.Cost
tForm.Description = tTB.Description
tTB.close
End Function
This is supost to post my Description and Cost fields.
Can anyone see the problem?