am currently developing for a company that recently purchased a new content management system. Due to the number of requested custom enhancements, the vendor phased the implementation. They delivered the upgrades as versioned DLLs to replace their predecessors at each phase.
This process, to no one's surprise, was very prone to error. The constant unregister, copy, and registration of new, versioned DLLs became incredibly tedious. After the second phase of enhancements I figured it would be worth my time to build a simple GUI to automate the process for future upgrades for any user.
I started this task by planning out my GUI and necessary controls. I needed three command buttons to select the components, remove selected components, or clear the list box. I would need a list box to display the selected components, two option buttons to dictate whether to register or unregister the components, and a command button to execute the procedure.
I wanted to be able to easily choose components from anywhere on our server, so I added a common dialog control. I duly named each of the controls and was ready to begin creating my sub-procedures and functions.
Even when I'm not writing DLLs or classes, I make it a point to maintain a componentized structure. Aside from the procedures for the form controls, I created separate sub-procedures or functions to handle instantiating the Windows Script Host Shell object (WSH Shell), destroying the shell object, and registering/unregistering the components.
Running Regsvr32.exe from the command line allows you to register one component at a time. I have 15 everytime there's an upgrade.
Build a simple GUI that uses the Windows Script Host to invoke the Windows Shell and loop over all your components from a list, passing them to Regsvr32.