Data Base Password (ADO)

Please discuss general Delphi programming topics here.

Data Base Password (ADO)

Postby Naser » March 29th, 2005, 9:19 pm

I want set database password in Access and open database in delphi without password.
Naser
Active Member
Active Member
 
Posts: 17
Joined: March 6th, 2005, 5:31 pm
Location: Iran - Esfahan

Postby Stefan » March 29th, 2005, 10:16 pm

I'm not entirely sure if I know what you mean but you can try this:

Create a file called "access.udl"

Edit that file (by double clicking on it)
- Select the Microsoft Jet 4.0 driver
- Go the next tabsheet and select the MDB file you wish to connect to
- Fill in the username "admin" and the password associated with that account
- Test the connection by clicking "Test Connection"
- Save the file

Back in your in Delphi project:

- Set the LoginPrompt property to false (assuming you are using a TAdoConnection).
- Set the ConnectionString property to "FILE NAME=Access.udl"
- Then try connecting by setting the Connected property to true.

Cheers,
Stefan
User avatar
Stefan
Moderator
Moderator
 
Posts: 128
Joined: September 27th, 2004, 9:40 am
Location: Tilburg, The Netherlands

Postby Naser » April 10th, 2005, 6:41 am

tanx

What Is Udl
Naser
Active Member
Active Member
 
Posts: 17
Joined: March 6th, 2005, 5:31 pm
Location: Iran - Esfahan

Postby Stefan » April 11th, 2005, 9:58 am

Hi,

UDL stands for Universal DataLink.
It's file-extenstion (.UDL) is linked to a little editor that allows you to easily configure connections to datasources.

Cheers,
Stefan
User avatar
Stefan
Moderator
Moderator
 
Posts: 128
Joined: September 27th, 2004, 9:40 am
Location: Tilburg, The Netherlands

Postby Naser » April 12th, 2005, 6:27 am

when enter password And user name : admin , an error happen : invalid password
sory , i english not very good .
bye
Naser
Active Member
Active Member
 
Posts: 17
Joined: March 6th, 2005, 5:31 pm
Location: Iran - Esfahan

Postby Stefan » April 12th, 2005, 7:17 am

Hi,

Are you sure you have selected the "Microsoft Jet 4.0 OLE DB Provider"?
Are you sure about the password? (is there a password? default the password is empty in MS Access).

Stefan
User avatar
Stefan
Moderator
Moderator
 
Posts: 128
Joined: September 27th, 2004, 9:40 am
Location: Tilburg, The Netherlands

Postby Naser » April 16th, 2005, 2:46 pm

Yes
can you build a delphi program with database password and send source for me ?

Tanx
Naser
Active Member
Active Member
 
Posts: 17
Joined: March 6th, 2005, 5:31 pm
Location: Iran - Esfahan

Postby Naser » April 16th, 2005, 2:48 pm

Naser
Active Member
Active Member
 
Posts: 17
Joined: March 6th, 2005, 5:31 pm
Location: Iran - Esfahan

Postby Stefan » April 19th, 2005, 7:15 am

I've sent a demo to your yahoo address... Let me hear how it went!

Stefan
User avatar
Stefan
Moderator
Moderator
 
Posts: 128
Joined: September 27th, 2004, 9:40 am
Location: Tilburg, The Netherlands


Return to Delphi Programming

Who is online

Users browsing this forum: No registered users and 0 guests

cron