Ah, I see what you are saying.
I don't know the reason why VBA/DAO does not supply the Type, Options, and
LockEdits. My guess is that some of these are specific to situations it
cannot make guesses about. For example, dbOpenTable should only be offered
if you are opening a recordset on a local (non-attached) Access table (not
query) only, and dbOpenDynamic should only be offered if you are working
through ODBC. I suspect it is just that it's not able to determine what to
offer.
Hopefully you are aware that you can place the cursor in the OpenRecordset
word, and press F1 to get help with the options.
There are other cases where the Intellisense supplies no lists or incomplete
lists. For example, the Visible property of a control is never offered in a
report, and no list is offered for the OutputFormat of SendObject.
In general, dbOpenDynaset is the safe and simple choice for OpenRecordset in
DAO.
HTH.
--
Allen Browne - Microsoft MVP. Perth, Western Australia.
Reply to group, rather than allenbrowne at mvps dot org.
Sreedhar said:
Hi Allen,
Example:
Dim db As DAO.Database -->Intellisense Works
Dim rst As DAO.Recordset -->Intellisense Works
Set db = CurrentDb
Set rst = db. -->Intellisense works
Set rst = db.OpenRecordset( -->I get the Syntax here
Set rst = db.OpenRecordset("tblCustomer", -->Intellisense ???
The above three sentences are repeated to show the stages where I get help
from Intellisense. For the [Type] and [Options] of the Recordset Object,
why
isn't the Intellisense working ? Or, is it specific to my PC ?
For ADO, we get the Intellisense helping out with CursorType, LockType
etc.
Had it been working for DAO too, I would have known long ago that there
are
types of Recordsets other than dbOpenDynaset.
--
Sreedhar
Allen Browne said:
Both ADO and DAO have a Recordset object.
You should get the enumeration if you disambiguate, e.g.:
Dim rs As DAO.Recordset
Access 2003, DAO 3.6, ADO 2.8
Intellisense works great all the time for ADO, but not for DAO. e.g.
enumerations like RecordsetType and RecordsetOption enumerations.
Unless I
go
to Object Browser and search for these, is there anyway to get
Intellisense
work here ?