473,394 Members | 2,160 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,394 software developers and data experts.

Connecting MS access with VB

How to connect MS access with VB
May 1 '07 #1
5 1749
Dököll
2,364 Expert 2GB
How to connect MS access with VB
Hello, prabakar!

You will need to do some reading:-)

Let me fetch the link.

Dököll
May 2 '07 #2
Dököll
2,364 Expert 2GB
How to connect MS access with VB
Here you go:

http://www.thescripts.com/forum/thread609151.html

Let me know how it turns out...
May 2 '07 #3
well the code below gives a connection to the database

dim db as new ADODB.connection

set db =new ADODB.connection

db.open="PROVIDER=Microsoft.jet.OLeDB.3.51;Data Source=" & App.Path & "\xxx.mdb;" this is for an access database, pls give your tablename in the xxx
this makes a coinnection, however u need a Recordset to actually add,delete or edit records

for this
dim rs as new ADODB.recordset
set rs =new ADODB.recordset
rs.Open "SELECT * from tablename", db, adOpenDynamic, adLockOptimistic


this makes a perfect connection and now with a more detailed program u can add and delete records.
May 2 '07 #4
debasisdas
8,127 Expert 4TB
Actually this is regarding the previous post

First of all select Microsoft ADO Object library.from Project---Reference

Next(regaring previous post)

In place of xxx instead of using tablename please use DATABASE name.

rest all is fine

and to open the recordset use TABLENAME in the SQL statment.
May 2 '07 #5
hmm he was correct! sorry for the mistake! Do as he said!
thats it
May 3 '07 #6

Sign in to post your reply or Sign up for a free account.

Similar topics

4
by: John Morgan | last post by:
I have Enterprise Manager on my local machine. For the last twelve months it has been connecting without problem to my online SQL Server database provided by my ISP. Three weeks ago the ISP...
12
by: Ann Marinas | last post by:
Hi all, I would like to ask for some help regarding separating the asp.net webserver and the sql server. I have created an asp.net application for a certain company. Initially, we installed...
5
by: bill | last post by:
I am having difficulties connecting to a remote Sql server database in VB.net. Lets say my remote server is found at 255.255.255.255 and its name is MyServer. The database is called MyDatabase....
5
by: Sebastian | last post by:
I'm using the following code to connect to an access 2000 database. (with reference to adodb) Public DBvar As New ADODB.Connection() DBvar.Open("Provider=Microsoft.Jet.OLEDB.4.0; Data...
3
by: BigZero | last post by:
hello i m new to php i m working on project that has interface with simple html and php i m thinking to use i got some problem with the connecting to DB here is the code for connecting db ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.