Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Error 3021 / Me.Recordset.AbsolutePosition = -1 on Form Load

Status
Not open for further replies.

Cyph3rM0nk

Programmer
Mar 19, 2004
5
US
Hello everyone,

I have a main single-form ("frmMain") which is based on a table named tblVendor. It contains a sub-form ("sfrmVenAddr") based on a seperate table named tblVenAddr. tblVendor has a 1-to-Many relationship with tblVenAddr because there are multiple locations for each vendor. These two tables are linked by a common field Ven_UID, which is an auto-number PK in tblVendor, and is a numeric long FK in tblVenAddr.

tblVendor
*Ven_UID (PK)
*Ven_Name

tblVenAddr
*VenLoc_UID (PK)
*VenAddr_L1
*VenAddr_L2
... etc
*Ven_UID (FK)

In design view, I verified that frmMain's RecordSource = tblVendor and sfrmVenAddr's RecordSource = tblVenAddr. But for some reason, when I open the form, there are no records loaded, and when I try to manipulate the Me.Recordset object in VB, I get Error 3021 "No Current Record".

Can anyone help?!?!?

Thanks!
 
Have you checked the Master and Child link fields of the subform ?

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ222-2244
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top