Opening a Table

G

Graham Mandeno

Hi Fred

Assuming you are using DAO:

Dim db as DAO.Database, rs as DAO.Recordset
Set db = CurrentDb
Set rs = db.OpenRecordset( "MyTable", dbOpenTable, _
dbDenyRead or dbDenyWrite)

If it's a linked table then you must open it as a dynaset and therefore
cannot specify dbDenyRead:

Set rs = db.OpenRecordset( "MyTable", dbOpenDynaset, dbDenyWrite)

--
Good Luck!
Graham Mandeno [Access MVP]
Auckland, New Zealand

Return mail address is invalid in a vain attempt to reduce spam.
Feedback is welcome at: [email protected]
Please post new questions or followups to newsgroup.
 
Top