Skip to main content
added 16 characters in body
Source Link
Vikalp Kapadiya
  • 945
  • 4
  • 12
  • 43

I have one Document Library in central administration Name "Deployment List" it contains SharePoint Solutions(WSP files). now i want to add and deploy that solution using c# code it already get file and deploy it form Local drive but i want to get that file(WSP file from Document Library). I am using Timer job to deploy that solution Note : Solution are farm solution

my code is as follow :

try
{
    // It give Error below line that "File not Found"
    SPSolution solution = SPFarm.Local.Solutions.Add("http://centraladmin/Deployment List/MySolution.wsp"); // It give Error here that "File not Found"

    Collection selectedWebApps = new Collection();

    SPWebApplication webApp = SPWebApplication.Lookup(new Uri("http://localhost:80"));

    selectedWebApps.Add(webApp);

    solution.DeployLocal(true, true);
}
catch
{
}

I get "File not found" exception when i try to add the solution to the farm.

Any idea how to solve this error?

I have one Document Library in central administration Name "Deployment List" it contains SharePoint Solutions(WSP files). now i want to add and deploy that solution using c# code it already get file and deploy it form Local drive but i want to get that file(WSP file from Document Library). I am using Timer job to deploy that solution Note : Solution are farm solution

my code is as follow :

try
{
    SPSolution solution = SPFarm.Local.Solutions.Add("http://centraladmin/Deployment List/MySolution.wsp"); // It give Error here that "File not Found"

    Collection selectedWebApps = new Collection();

    SPWebApplication webApp = SPWebApplication.Lookup(new Uri("http://localhost:80"));

    selectedWebApps.Add(webApp);

    solution.DeployLocal(true, true);
}
catch
{
}

I get "File not found" exception when i try to add the solution to the farm.

Any idea how to solve this error?

I have one Document Library in central administration Name "Deployment List" it contains SharePoint Solutions(WSP files). now i want to add and deploy that solution using c# code it already get file and deploy it form Local drive but i want to get that file(WSP file from Document Library). I am using Timer job to deploy that solution Note : Solution are farm solution

my code is as follow :

try
{
    // It give Error below line that "File not Found"
    SPSolution solution = SPFarm.Local.Solutions.Add("http://centraladmin/Deployment List/MySolution.wsp"); 

    Collection selectedWebApps = new Collection();

    SPWebApplication webApp = SPWebApplication.Lookup(new Uri("http://localhost:80"));

    selectedWebApps.Add(webApp);

    solution.DeployLocal(true, true);
}
catch
{
}

I get "File not found" exception when i try to add the solution to the farm.

Any idea how to solve this error?

I have one Document Library in central administration Name "Deployment List" it contains SharePoint Solutions(WSP files). now i want to add and deploy that solution using c# code it already get file and deploy it form Local drive but i want to get that file(WSP file from Document Library). I am using Timer job to deploy that solution Note : Solution are farm solution

my code is as follow :

try
{
    SPSolution solution = SPFarm.Local.Solutions.Add("http://centraladmin/Deployment List/MySolution.wsp"); // It give Error here that "File not Found"

    Collection selectedWebApps = new Collection();

    SPWebApplication webApp = SPWebApplication.Lookup(new Uri("http://localhost:80"));

    selectedWebApps.Add(webApp);

    solution.DeployLocal(true, true);
}
catch
{
}

can anybody haveI get "File not found" exception when i try to add the solution to the farm.

Any idea how to solve this error?

I have one Document Library in central administration Name "Deployment List" it contains SharePoint Solutions(WSP files). now i want to add and deploy that solution using c# code it already get file and deploy it form Local drive but i want to get that file(WSP file from Document Library). I am using Timer job to deploy that solution Note : Solution are farm solution

my code is as follow :

try
{
    SPSolution solution = SPFarm.Local.Solutions.Add("http://centraladmin/Deployment List/MySolution.wsp"); // It give Error here that "File not Found"

    Collection selectedWebApps = new Collection();

    SPWebApplication webApp = SPWebApplication.Lookup(new Uri("http://localhost:80"));

    selectedWebApps.Add(webApp);

    solution.DeployLocal(true, true);
}
catch
{
}

can anybody have idea how to solve this error?

I have one Document Library in central administration Name "Deployment List" it contains SharePoint Solutions(WSP files). now i want to add and deploy that solution using c# code it already get file and deploy it form Local drive but i want to get that file(WSP file from Document Library). I am using Timer job to deploy that solution Note : Solution are farm solution

my code is as follow :

try
{
    SPSolution solution = SPFarm.Local.Solutions.Add("http://centraladmin/Deployment List/MySolution.wsp"); // It give Error here that "File not Found"

    Collection selectedWebApps = new Collection();

    SPWebApplication webApp = SPWebApplication.Lookup(new Uri("http://localhost:80"));

    selectedWebApps.Add(webApp);

    solution.DeployLocal(true, true);
}
catch
{
}

I get "File not found" exception when i try to add the solution to the farm.

Any idea how to solve this error?

Tweeted twitter.com/#!/StackSharePoint/status/325608722263064577
Source Link
Vikalp Kapadiya
  • 945
  • 4
  • 12
  • 43

Add and deploy SharePoint Farm Solutions from Document Library using C# code

I have one Document Library in central administration Name "Deployment List" it contains SharePoint Solutions(WSP files). now i want to add and deploy that solution using c# code it already get file and deploy it form Local drive but i want to get that file(WSP file from Document Library). I am using Timer job to deploy that solution Note : Solution are farm solution

my code is as follow :

try
{
    SPSolution solution = SPFarm.Local.Solutions.Add("http://centraladmin/Deployment List/MySolution.wsp"); // It give Error here that "File not Found"

    Collection selectedWebApps = new Collection();

    SPWebApplication webApp = SPWebApplication.Lookup(new Uri("http://localhost:80"));

    selectedWebApps.Add(webApp);

    solution.DeployLocal(true, true);
}
catch
{
}

can anybody have idea how to solve this error?