Search Blogs AGI.com Blogs

UI Plugins: To Register or Not to Register

By: Ismir Tufek

We have two ways to add a UI Plugin to STK. Both methods require that XML file is placed in Plugins folder in either STK install area, the user configuration area, or the ProgramData area.

The “COM” registration is a process of registering a plugin in GAC (Global Assembly Cache), which requires administrator rights. In that case, the XML file only needs the Product ID of the plugin.

The “registry free” registration, or as it is referred in help “.net registration,” does not require administrator rights, but the XML file has to include information about the exact location of the plugin, dll name, and the entry point. Since the exact location is not known until the plugin is actually installed, the XML file needs to be created/updated as a part of the installation.

While “COM” and “.net” registration are appropriate terms, I prefer to use “registered” and “registry free” instead. I worked with customers who confused terms: .net application and .net registration. Any C# or vb.net application is considered a .net application, but they can still be registered if the appropriate flags are set. They did not understand that the registration method and the application type are completely separate because they share the same work: .net. Since the official terms caused so much confusion, I prefer to use layman’s terms.

In general, any installation needs to be able to clean up after itself (I wish my kids would learn that lesson) and include an uninstall process. Since the list of the installed applications is kept in the registry, it would be logical to use registered plugins because your installation is already updating the registry. However, more and more users do not have administrator rights on their computers. Registry free plugins are a solution to get around the security restrictions.

STK 11 comes in both x32 bit and x64 bit configurations. The registered plugins have to be configured for a specific version of the STK, which means that you might need to maintain two versions of your plugin. The registry free plugins do not have this limitation. The registry free plugins do have a limitation of needing to know the full path to the plugin. I have created a helper application to help me distribute registry free plugins. I will discuss the helper application in a future blog.

Posted: 11/11/2016 10:08:36 AM


Tags

Dev