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 biv343 on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How Do I access a table withing the same database as the VBA

Status
Not open for further replies.

WhiteZiggy

Programmer
Jan 22, 2003
85
US
Ok,

I need to use a field (names.txt) with the table (me.tbl) to run this macro (Malcom). I need to run (Malcom) for every line in the table (Malcom(names.txt)). I know how to connect my access DB to outside tables, but for some reason am having a brain lapse as to how to utilize a table within the same DB as the VBA and all my books are currently in storage.

If anyone can help it would be appreciated...

Thanks,
WZ

Sample:

Function CountFolder()
'Runs for every file that is being created


Malcom(names.txt)

'Of course i will cycle through the table or SQL recordset
' That I will get once i figure the best way to connect
'to the table

End Function
 
K,

Nevermind, I got the connection. But I do have one more little prob.

My query gives me duplicates. Which is fine for the query. But I want to just get the unique ones when i access it as a recordset through the VBA...

Any suggestions??

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top