.NET

.NET

Reply
*GPaolo
Message 1 of 5 (268 Views)

How i can use "UserConfigurationManager"

268 Views, 4 Replies
02-06-2007 05:48 AM
I need to import or export the current profile in a file named .ARG

I think that the class that make this is :

Autodesk.autocad.application.UserConfigurationManager.OpenCurrentProfile()

but i don't find some example or explanation.

Dim i As Autodesk.AutoCAD.ApplicationServices.IConfigurationSection

i =
Autodesk.AutoCAD.ApplicationServices.Application.UserConfigurationManager.Op
enCurrentProfile()

thanks in advance

GPaolo
*Kerry Brown
Message 2 of 5 (268 Views)

Re: How i can use "UserConfigurationManager"

02-07-2007 12:35 PM in reply to: *GPaolo
I think you may have to use Com interop AcadPreferences

something like
acadPref.Profiles.ImportProfile("TESTPROFILE", "c:\\TESTPROFILE.ARG", True)

If you find a way in the NET API from the wrapped Library I'd like to know.

/// kwb

"GPaolo" wrote in message
news:5476316@discussion.autodesk.com...
I need to import or export the current profile in a file named .ARG

I think that the class that make this is :

Autodesk.autocad.application.UserConfigurationManager.OpenCurrentProfile()

but i don't find some example or explanation.

Dim i As Autodesk.AutoCAD.ApplicationServices.IConfigurationSection

i =
Autodesk.AutoCAD.ApplicationServices.Application.UserConfigurationManager.Op
enCurrentProfile()

thanks in advance

GPaolo
*GPaolo
Message 3 of 5 (268 Views)

Re: How i can use "UserConfigurationManager"

02-07-2007 10:50 PM in reply to: *GPaolo
I already use Com Interop
something like
acadPref.Profiles.ImportProfile("TESTPROFILE", "c:\\TESTPROFILE.ARG", True)
'---------------------------------------------------
I want make a complete unmanaged application.
Bye.

"Kerry Brown" ha scritto nel messaggio
news:5478747@discussion.autodesk.com...
I think you may have to use Com interop AcadPreferences

something like
acadPref.Profiles.ImportProfile("TESTPROFILE", "c:\\TESTPROFILE.ARG", True)

If you find a way in the NET API from the wrapped Library I'd like to know.

/// kwb

"GPaolo" wrote in message
news:5476316@discussion.autodesk.com...
I need to import or export the current profile in a file named .ARG

I think that the class that make this is :

Autodesk.autocad.application.UserConfigurationManager.OpenCurrentProfile()

but i don't find some example or explanation.

Dim i As Autodesk.AutoCAD.ApplicationServices.IConfigurationSection

i =
Autodesk.AutoCAD.ApplicationServices.Application.UserConfigurationManager.Op
enCurrentProfile()

thanks in advance

GPaolo
*Tony Tanzillo
Message 4 of 5 (268 Views)

Re: How i can use "UserConfigurationManager"

02-11-2007 12:50 AM in reply to: *GPaolo
I'm pretty sure that the COM implementation is
just reading the registry directly. You can do that
yourself, althought its obviously more work than
just using COM.

--
http://www.caddzone.com

AcadXTabs: MDI Document Tabs for AutoCAD 2004/2005/2006/2007
http://www.acadxtabs.com

"GPaolo" wrote in message news:5479224@discussion.autodesk.com...
I already use Com Interop
something like
acadPref.Profiles.ImportProfile("TESTPROFILE", "c:\\TESTPROFILE.ARG", True)
'---------------------------------------------------
I want make a complete unmanaged application.
Bye.

"Kerry Brown" ha scritto nel messaggio
news:5478747@discussion.autodesk.com...
I think you may have to use Com interop AcadPreferences

something like
acadPref.Profiles.ImportProfile("TESTPROFILE", "c:\\TESTPROFILE.ARG", True)

If you find a way in the NET API from the wrapped Library I'd like to know.

/// kwb

"GPaolo" wrote in message
news:5476316@discussion.autodesk.com...
I need to import or export the current profile in a file named .ARG

I think that the class that make this is :

Autodesk.autocad.application.UserConfigurationManager.OpenCurrentProfile()

but i don't find some example or explanation.

Dim i As Autodesk.AutoCAD.ApplicationServices.IConfigurationSection

i =
Autodesk.AutoCAD.ApplicationServices.Application.UserConfigurationManager.Op
enCurrentProfile()

thanks in advance

GPaolo
*Expert Elite*
Sinc
Posts: 6,207
Registered: ‎11-18-2006
Message 5 of 5 (268 Views)

Re: How i can use "UserConfigurationManager"

02-19-2007 11:11 PM in reply to: *GPaolo
The UserConfigurationManager provides access to specific locations in the registry. Access it like this:

UserConfigurationManager ucm = Autodesk.AutoCAD.ApplicationServices.Application.UserConfigurationManager;
IConfigurationSection regbase = ucm.OpenGlobalSection();

For OpenGlobalSection(), regbase is the primary Civil-3D entry in HKCU/Software/Autodesk.
Sinc
Post to the Community

Have questions about Autodesk products? Ask the community.

New Post
Announcements
Do you have 60 seconds to spare? The Autodesk Community Team is revamping our site ranking system and we want your feedback! Please click here to launch the 5 question survey. As always your input is greatly appreciated.