473,385 Members | 1,486 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,385 software developers and data experts.

Connection Between access table and VB6 when database is password protected

1
Dim con5 As New ADODB.Connection
Dim rs5 As New ADODB.Recordset
Private Sub Command1_Click()
con5.Provider = "Microsoft.JET.OLEDB.4.0;"
con5.Open App.Path + "\da.mdb"
rs5.Open "[DEMO]", con5, adOpenStatic, adLockOptimistic


'The above code can't work when the database is protected.
'Please Tell, How can I solve it.
Nov 21 '14 #1
1 1151
use this connection string:

con5 = "Provider=Microsoft.Jet.OLEDB.4.0;" & "Data Source=" & App.Path & "\da.mdb;" & "Jet OLEDB:Database Password=yourdatabasepassword;"
Jan 11 '15 #2

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

Similar topics

4
by: Kelly Bowles | last post by:
I have made a purchase requistion which I have been asked to put password protected copy of requestors signature. I am thinking that each signature will have to be scanned as a picture and linked...
3
by: Chris | last post by:
I have a frontend that has some tables which are linked to a backend. Now I want to make the backend password protected and when I try to run it password protected I can't open it. In the first...
4
by: anand | last post by:
Hi, I have an Access 2000 database, which contains some native tables, and some linked tables which belong to an ORACLE database, through ODBC. Using VB.NET, I am trying to fetch some data by...
8
by: ablyplus | last post by:
Hi, I am trying to open MS Access DB with c# like follows... OleDbConnection thisConnection = new OleDbConnection( @"Provider=Microsoft.Jet.OLEDB.4.0;" + @"Data Source=" + @"..\..\hren.mdb;"...
0
by: Phil Haddock | last post by:
Hi, I'm converting an existing Access application to vb.net 2003. The application allows users to select a number of tables from an ODBC data source, and nominate names for each table to use...
4
by: kthiagar | last post by:
Hi I am trying to connect to a password protected access file from VB.NET. I have no problem in connecting to Access, if I remove the password. This is what I am doing: In the server explorer,...
3
by: -xx- | last post by:
Hi, I am new to c# and just trying out c# with ms access. First problem i encountered is how do i open up ms access that has password. Here is my current codes which working fine if there is...
3
by: Porthos | last post by:
I'm currently working on a project for my stage and im having slight problems accessing a locked MS Access table I have password and username for the table but i can't seem to figure out how to...
0
by: Ganesh Kulkarni | last post by:
In Microsoft SQL 2005 I'm trying to import from a table of a password protected Microsoft Access database file, by using OPENROWSET command, but it's not working. here is my code: INSERT INTO...
3
by: jeniferleon | last post by:
I got a corruption error in my access database due to which I lost my access(MDB/ACCDB) table. I need to get back that deleted access file as soon as possible and i don't know what should I do?...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
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...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

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.