c# - Adding a reference assembly to script task and deploying -


i'm working on ssis project contains single script task. job of script task upload text file sharepoint site library. i'm using microsft.sharepoint.client , microsoft.sharepoint.runtime achieve this. code simple.

string sharepointsite = @"https://server.com";              using (clientcontext ctx = new clientcontext(sharepointsite))             {                 web currentweb = ctx.web;                  ctx.load(currentweb);                  ctx.executequery();                  using (filestream fs = new filestream(@"z:\samplefile.txt", filemode.open))                 {                     microsoft.sharepoint.client.file.savebinarydirect(ctx, "/sites/subsite/library/testfile client.txt", fs, true);                  }                  console.writeline("uploaded file successfully");             } 

this works expected visual studio. if package different server,i'm not sure if dll's packaged along deployment file. have set 'copy local' property of reference true. in .net application, dll file gets copied on bin folder. in case of ssis script task, should copied dll?

you need make sure dll's referenced ssis script component deployed in prod server under "c:\windows\microsoft.net\assembly\" ssis package not move dll's.


Comments

Popular posts from this blog

PySide and Qt Properties: Connecting signals from Python to QML -

c# - DevExpress.Wpf.Grid.InfiniteGridSizeException was unhandled -

scala - 'wrong top statement declaration' when using slick in IntelliJ -