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

Add username/password to newly created MDB

I am trying to create a new mdb in C# using ADOX, i am able to create
DB , i want to add a username/password on that db , i have tried so
many things , cant make it to work , please help

ADOX.CatalogClass cat = new ADOX.CatalogClass();

cat.Create("Provider=" + provider + ";" +
"Data Source=" + databaseName + ";" +
"Jet OLEDB:Engine Type=5");

ADODB.ConnectionClass conn = new ConnectionClass();
conn.ConnectionString = string.Format("Provider={0};Data
Source={1};", provider,databaseName);
conn.Open("","","",0);
ADOX.UserClass user = new UserClass();
user.Name = userName;
user.ChangePassword("",password);
// FAILS HERE , cant make this method to work.
cat.Users.Append(user,password);
Nov 16 '05 #1
0 1570

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: compassSoftware | last post by:
Hi, When I create a new database from Enterprise Manager (right click on databases > New Database) I noticed that I am not prompted to create a password or user name. Can I take it then that all...
2
by: Mark | last post by:
In this article http://support.microsoft.com/?id=329290 I will have to perform this in my installation. The question is since the aspnet_setreg.exe does not automatically grant the asp.net service...
6
by: Anita | last post by:
I have problem opening my existing projects or newly created project. It asks me for user name and password and if I provide then it allows me to open but when I debug either it gives error message...
8
by: Philip Wagenaar | last post by:
I need to send printjobs to a printqueue under diffrent usernames. The printsoftware on the queue is not very 'secure' so I can create a user on 1 system and send a printjob under it's name to the...
11
by: Kevin O'Brien | last post by:
Hello, I am creating a sign on screen for my application in which I want to store the username and password in a database table. I was thinking of putting a combo box connected to the database...
2
by: sankaba | last post by:
Hi, I have created a new user for a database that i hav created in DB2, by expanding the database tree diagram in control center right upto DB users folder, and then right clicking it and...
5
by: libra786 | last post by:
I have created a blog and have added a login box which prompts the user for login and id before posting- The username and password have been stored in the database, however when i enter the username...
0
by: roamnet | last post by:
hi i created database file with .mdf extention ,sql server as a source and use grid view to display data there're no problem in data retrieve and display,but i want to edit it or insert new...
2
by: poolboi | last post by:
hey guys i got the code below to authenticate users for database #!perl\bin\perl use strict; use warnings; use DBI();
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: 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
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
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: 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
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
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
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...

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.