You should write a program to deploy your program.
Thats what i did. I wrote a console application, and then sent a link in an email to everyone in my company. When they clicked it, it copied the necessary files, and then wrote the correct values to the registry......
Here is the program.
Sub InitialRegistryEditor()
Dim AppKey As RegistryKey = Nothing
Dim CommandKey As RegistryKey = Nothing
Dim VersionKey As RegistryKey = Nothing
Dim TempVal As Object = Nothing
Try
Console.WriteLine(vbCrLf + "LDD Registry Editor. Created by Mark Pendergraft" + vbCrLf + "Attempting to access the registry...." + vbCrLf)
'If this key doesn't exist, they don't have AutoCAD 2006 - Version Specific as far as i know!!!
If Not My.Computer.Registry.GetValue("HKEY_LOCAL_MACHINE\SOFTWARE\Autodesk\AutoCAD\R16.2\ACAD-4008:409", "AcadLocation", Nothing) Is Nothing Then
My.Computer.Registry.LocalMachine.GetAccessControl()
'Get the key, seeing that it exists
AppKey = My.Computer.Registry.LocalMachine.CreateSubKey("SOFTWARE\Autodesk\AutoCAD\R16.2\ACAD-4008:409\Applications\MRPTools")
'let the user know whats happening
Console.WriteLine("Successfuly Created " + AppKey.ToString)
'These are the values you will have to write (for 2006)
AppKey.SetValue("DESCRIPTION", "MRPTools", RegistryValueKind.String)
'this is where the dll file resides on your machine
AppKey.SetValue("LOADER", "C:\Program Files\Autodesk Land Desktop 2006\NET\MRPTools.dll", RegistryValueKind.String)
AppKey.SetValue("LOADCTRLS", 2, RegistryValueKind.DWord)
AppKey.SetValue("MANAGED", 1, RegistryValueKind.DWord)
CommandKey = AppKey.CreateSubKey("COMMAND")
Console.WriteLine("Successfully Created " + CommandKey.ToString)
'this is a public sub inside MRPTools.dll, You will have to set it to a Public sub residing in your program.
CommandKey.SetValue("LM", "LSMan", RegistryValueKind.String)
Else
Console.WriteLine("The Key does not exist on your machine.")
Console.WriteLine("Please speak to your IT Professional to determine the issue.")
Console.WriteLine("Exiting....")
Exit Sub
End If
Catch ex As Exception
Console.WriteLine(ex.Message)
Console.WriteLine(vbCrLf + "Press Any Key to Continue...")
Console.ReadKey()
End Try
End Sub
'''''''''''''''''''''''''''''''''''
obviously this is version specific to AutoCAD 2006. But you get the idea. anyways, thats how i deployed my program inside AutoCAD for my company, and it works very well.
I hope that helps 🙂
-Mark Pendergraft