none
Creating a transform component in a custom transform component RRS feed

  • Question

  • Hello

    Thanks for all the help on this forum thus far! I want to wrap a standard transform component or components in a custom transform component i.e. create them at run time, set their properties and get them to execute.
    An example: I need to create a wrapper onto the Lookup Transform that exposes business logic that is part of our software and also allows multiple lookups to run within a single transform. When my custom transform component runs I need to internally create multiple lookup transforms, set their properties and delegate execution. The only challenge I see here is getting a reference to the MainPipe so I can call ComponentMetaDataCollection.New(). Looking at the PipeLineComponent base class I don't see a reference to the MainPipe. Coding the rest looks do-able although rather painful (looking up class ids and setting up columns etc). Any advice appreciated.

    Thanks
    T
    Tuesday, January 26, 2010 3:29 PM

Answers

  • Unfortunately, you can not do what you're asking to do.

    Custom components (and Tasks) aren't provided any information about any other components (or Tasks) within the package.  There is no way for them to "hook up" to anything.  You can also not dynamically create elements within the Control Flow or Data Flow inside an already running package.

    You have two alternatives.  First, you can construct the package (or part of it) programatically.  Duane Douglas' blog is a great resource for that.  Second, you may be able to leverage the same trick the SCD Wizard does - as it constructs multiple components on the design surface when you first drop it.  Look at Developing a User Interface for a Data Flow Component for info about the IDtsPipelineEnvironmentService.
    Todd McDermid's Blog
    • Marked as answer by T Rex Wednesday, January 27, 2010 6:54 AM
    Tuesday, January 26, 2010 6:02 PM
    Moderator

All replies

  • Unfortunately, you can not do what you're asking to do.

    Custom components (and Tasks) aren't provided any information about any other components (or Tasks) within the package.  There is no way for them to "hook up" to anything.  You can also not dynamically create elements within the Control Flow or Data Flow inside an already running package.

    You have two alternatives.  First, you can construct the package (or part of it) programatically.  Duane Douglas' blog is a great resource for that.  Second, you may be able to leverage the same trick the SCD Wizard does - as it constructs multiple components on the design surface when you first drop it.  Look at Developing a User Interface for a Data Flow Component for info about the IDtsPipelineEnvironmentService.
    Todd McDermid's Blog
    • Marked as answer by T Rex Wednesday, January 27, 2010 6:54 AM
    Tuesday, January 26, 2010 6:02 PM
    Moderator
  • Thanks again for the great advice, after reading your reply a lot of ideas came together and I think constructing the package programatically will be the way to go for me.
    Wednesday, January 27, 2010 6:55 AM