Starting with version 1.34, VB Migration Partner can migrate the Printer, CommonDialog, Line and Shape classes by means of the new CodeArchitects.VBPowerPack.dll library, which has the advantage of not depending on any COM DLL.
This article explains how you can modify projects that are already migrated to leverage the new DLL and therefore avoid (or at least, reduce) dependencies from COM. Basically, this process has the following steps.
- Add a reference to the CodeArchitects.VBPowerPack.dll and Microsoft.VisualBasic.PowerPacks.Vs.dll files.
- add a project-level import for the CodeArchitects.VBPowerPack namespace.
- modify the VisualBasic6_Support.vb file (located in the My Project and hidden by default) so that all reference to VB6Printer and VB6Printers classes is changed into VB6PrinterPP and VB6PrintersPP, respectively.
- check the Error List window and look whether your code uses one or more members that have been obsoleted. In this case, your code is guaranteed not to work as it did before the changes.
- Carefully read this article to check whether other incompatibilities or important differences can affect the way your code behaves.