This project is read-only.
Install it, Configure-it & Run-it…

Please consider this Post-build event

path "C:\Program Files\Microsoft SDKs\Windows\v6.0A\bin"
gacutil /uf "SSISDownloadFileTask100"
del "C:\Program Files (x86)\Microsoft SQL Server\100\DTS\Tasks\SSISDownloadFileTask100.dll"
copy "$(TargetDir)SSISDownloadFileTask100.dll" "C:\Program Files (x86)\Microsoft SQL Server\100\DTS\Tasks\"
gacutil -i "$(TargetDir)SSISDownloadFileTask100.dll"

First of all, you have to add the component to the ToolBox in the category “Control Flow Items” in the usual way… right click, you choose the “SSIS Control Flow Items” You search and check “Execute Assembly Task” and the OK button.
 
image 
Did you see the Icon and Label of the component in the ToolBox?

image 
 
.. so, drag it into the design surface
 
image 

Create a HTTP Connection…

image

… and then eventually, you can add some variables as follows:

 

image

…add a Script Task

image

Double-click-it… and add these variables in the ReadWriteVariable row…

image

… add the following code after you clicked the button “Edit Script”, just to simulate how it works with variables. Imagine a scenario within a “Foreach Loop Container” when you iterate through in a loop cycle and you build your source URL and/or destination file location dynamically…

public void Main()
        {
            Dts.Variables["SourceURL"].Value = @"http://download.codeplex.com/download?ProjectName=ssisassembly&DownloadId=145242";
            Dts.Variables["SourceFile"].Value = @"";
            Dts.Variables["DestinationFolder"].Value = @"C:\";
            Dts.Variables["DestinationFile"].Value = @"SSISTestProject.rar";

            Dts.TaskResult = (int)ScriptResults.Success;
        }

Save your code, quit the editor and then double-click on the component “Download File Task” you already added and you will see the configuration window.

 

image

So, choose your HTTP connection and if you click image button you will see the “Expression Builder” Window. Right-now you can compose your “Source file” / “Destination file” as you saw in the previous image.

image

Click the Save button and link the two components:

image

 

Enjoy-it!

Last edited Aug 8, 2011 at 11:49 AM by cosminfr, version 5

Comments

No comments yet.