3 Posts
0 Kudos
Registered: ‎06-22-2012
Post 1 of 2

Database Login

143 Views, 1 Replies
06-22-2012 03:34 AM

I am working on an application which uses an oracle database as backend. The aplication uses a login dialog in


 void IExtensionApplication.Initialize()

so my application knows the credentials for the oracle database. I use a a drawing-template which has a databaselink in it. This points to a UDL-file  in 'Data Linls'. If i add the Credentials to this file and set the Parameter Persist Security Info=True the Credentials are ignored. So i thought i can avoid the additional loginprocesses if I add the following code:

var acadApp = (Autodesk.AutoCAD.Interop.AcadApplication)Autodesk.AutoCAD.ApplicationServices.Application.AcadApplication;
dynamic caoConnect = acadApp.GetInterfaceObject("CAO.DBConnect.16");


If i dont execute the code above i need two logins for the new drawing. After I added the code to my application I still need one oft this.


Can somebody lead me to the point where the second login comes from. I use AutoCAD Map 3D 2012. Maybe someone has already explained the problem, in this case please led me to the corresponding thread.


best regards

Markus Strauss

Distinguished Mentor
582 Posts
91 Kudos
Registered: ‎04-11-2010
Post 2 of 2

Re: Database Login

06-22-2012 10:59 AM in reply to: straussm



It seems that there are 2 connections and so 2 credentials are needed, may be one for CAO and the one for ADO.NET or FDO if you are using it. I don't know if the two connections are required for your workflow, but it's not uncommon if you need to access 2 different kind of data on 2 different datasources.


Persist Security Info=True , only means that the credential info it's retained after the connection is established, and so you can recover that info from the connection, usually you set it to false for security. But the credentials are needed every time you need a connection, no matter if it's set to true or false.


Gaston Nunez







Post to the Community

Have questions about Autodesk products? Ask the community.

New Post