Jobs
Author: Rushabh Date Submitted: 4/8/2005 Category: Database Compatibility: VB 6 This code has been accessed 7546 times.
Email Yourself this snippet:
dim conn as adodb.connection dim rs as adodb.recordset
Code
'assume that u have database temp in ur application path named temp.mdb 'this will help to open this database data1.databasename = app.path & "\temp.mdb" data1.refresh conn.open ""'here add connection string" rs.open "select * from table",conn,adopenstatic,adlockreadonly if not(rs.eof and rs.bof) then rs.movefirst while not rs.eof data1.recordset.addnew data1.recordset("field1")=rs("field") 'Likewise enter all fields u want data1.recordset.update rs.movenext end if rs.close conn.close set conn=nothing