< g >
--
Ken Snell
<MS ACCESS MVP>
"TC" <(E-Mail Removed)> wrote in message news:1059799979.239599@teuthos...
> Give up, Ken!!
>
> TC
>
>
> "Tim" <(E-Mail Removed)> wrote in message
> news:068a01c358a6$72966460$(E-Mail Removed)...
> > Ken,
> >
> > Sorry, I missed some code from the line.
> >
> > Set rst = db.OpenRecordset("select ID from qryemp;")
> >
> > The correct one is the following:
> >
> > Set rst = db.OpenRecordset("select ID from qryemp-ID;")
> >
> > When I ran the sub, I got error message. Could you tell
> > me how to fix it?
> >
> > Thanks.
> >
> > Tim.
> >
> > >-----Original Message-----
> > >What do you mean by "it didn't work"?
> > >
> > >--
> > > Ken Snell
> > ><MS ACCESS MVP>
> > >
> > >"Tim" <(E-Mail Removed)> wrote in message
> > >news:060601c35895$f966c860$(E-Mail Removed)...
> > >> Hi everyone,
> > >>
> > >> I created a recordset from query. But, it didn't work.
> > >> Could anyone can help me?
> > >>
> > >>
> > >> Dim db As Database
> > >> Dim rst As Recordset
> > >>
> > >> Set db = CurrentDb
> > >> Set rst = db.OpenRecordset("select ID from qryemp;")
> > >>
> > >> Debug.Print rst.Fields("ID").Value
> > >>
> > >>
> > >> Thanks in advance.
> > >>
> > >> Tim.
> > >
> > >
> > >.
> > >
>
>
|