I am trying to edit a SSIS package from code using ManagedDTS dlls (and others) and I need to access one of the connections defined in the package in order to re-map the columns in one of the source components. The problem is that this connection is created with a custom connection manager and it is therefore not recognized, when the package is loaded. The code should be something like this:
Application app = new Application();
Package package = app.LoadPackage("packagepath", null);
var customConnection = package.Connections["customConnectionManager"];
Where the customConnection is the connection that I am looking for.
I am able to create a new package with this type of connection but as soon the package is saved and reloaded, I don't have access to it. The custom connection manager is in GAC and can be normally used in VS SSDT. When I make a new package in add the connection "customConnectionManager" is works as intended.
Is there a way to access connections in the SSIS packages that are made with custom connection managers?
Thanks in advance!