Article View: borland.public.cppbuilder.database.ado
Article #5208How to create an Access DB with Database Password
From: Iñigo Campos Troncoso
Date: Wed, 04 Jul 2001 09:16
Date: Wed, 04 Jul 2001 09:16
30 lines
1617 bytes
1617 bytes
Hi.
My application creates some DB Access from code. Form that I use the
next code:
int x,y;
char szAttributes[300];
char *szDriver = "Microsoft Access Driver (*.mdb)";
AnsiString PathCompleto = directorio + "\\" + NombreBD;
char *szPathDb = PathCompleto.c_str();
sprintf(szAttributes, "CREATE_DB=\"%s\" General;;",szPathDb);
for (x = strlen(szAttributes), y = 0;y<x;y++)
{
if (szAttributes[y] == ';')
szAttributes[y] = '\0';
}
return
SQLConfigDataSource(NULL,ODBC_CONFIG_SYS_DSN,szDriver,szAttributes);
But this creates a DB without a Database Password.
I want to create the same DB, but with a Database Password.
Anybody knows how to do that.
Thanks
Technical Details
Message-ID:
<3B42DED2.95D37D84@integratel.es>Path:
arc1-ca.pugleaf.net!archiver1.google.com!newsfeed.google.com!sn-xit-02!supernews.com!newsfeed.direct.ca!look.ca!newsfeed.wirehub.nl!PeerFeed.KWeb.on.ca!dnewsShow Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 10698b,a4b594ef304c47c,start X-Google-Attributes: gid10698b,public X-Google-ArrivalTime: 2001-07-04 02:18:08 PST Message-ID: <3B42DED2.95D37D84@integratel.es> Date: Wed, 04 Jul 2001 11:16:02 +0200 From: Iñigo Campos Troncoso <icampos@integratel.es> X-Mailer: Mozilla 4.75 [en] (Windows NT 5.0; U) X-Accept-Language: en MIME-Version: 1.0 Newsgroups: borland.public.cppbuilder.database.ado Subject: How to create an Access DB with Database Password Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit NNTP-Posting-Host: 212.166.138.15 X-Trace: dnews 994238121 212.166.138.15 (4 Jul 2001 02:15:21 -0700) Lines: 31 Path: arc1-ca.pugleaf.net!archiver1.google.com!newsfeed.google.com!sn-xit-02!supernews.com!newsfeed.direct.ca!look.ca!newsfeed.wirehub.nl!PeerFeed.KWeb.on.ca!dnews