0

Update1:

PS C:\> Add-SPSolution c:\Deployment\MyFirstWebPart.wsp Install
-SPSolution -Identity NameOfWSP -WebApplication http://sp2010 -GACDeployment
Add-SPSolution : A positional parameter cannot be found that accepts argument '
Install-SPSolution'.
At line:1 char:15
+ Add-SPSolution <<<<  c:\Deployment\MyFirstWebPart.wsp Install-SPSolution
-Identity NameOfWSP -WebApplication http://sp2010 -GACDeployment
    + CategoryInfo          : InvalidArgument: (:) [Add-SPSolution], Parameter
   BindingException
    + FullyQualifiedErrorId : PositionalParameterNotFound,Microsoft.SharePoint
   .PowerShell.SPCmdletAddSolution

end update

update:

Add-SPSolution C:\Visual Studio 2010\Projects\Deployment\MyFirstWebPart.wsp Install-SPSolution –Identity NameOfWSP –WebApplication http://sp2010 -GACDeployment

error:

     PS C:\> Add-SPSolution C:\Visual Studio 201
0\Projects\Deployment\MyFirstWebPart.wsp Install-SPSolution -Identity NameOf
WSP -WebApplication http://sp2010 -GACDeployment
Add-SPSolution : A positional parameter cannot be found that accepts argument '
Studio'.
At line:1 char:15
+ Add-SPSolution <<<<  C:\Visual Studio 2010\Projects\D
eployment\MyFirstWebPart.wsp Install-SPSolution -Identity NameOfWSP -WebApp
lication http://sp2010 -GACDeployment
    + CategoryInfo          : InvalidArgument: (:) [Add-SPSolution], Parameter
   BindingException
    + FullyQualifiedErrorId : PositionalParameterNotFound,Microsoft.SharePoint
   .PowerShell.SPCmdletAddSolution

end update

I could not find an answer deploying my custom webpart from one sharepoint 2010 server to another server (sharepoint 2010)

i have a farm solution custom-webpart developed in sharepont 2010 and i want to move to my webpart to different environement.

can anybody give me step-by-step like how to deploy?

thanks.

PS: VS2010, SP2010

5
  • Have you tried searching the site? I found this question which looks to be an exact duplicate sharepoint.stackexchange.com/questions/17779/…
    – Kit Menke
    Sep 1, 2011 at 13:42
  • 1
    Should be a case of just deploying the WSP to the other farm. Are you have any problems in particular?
    – James Love
    Sep 1, 2011 at 13:42
  • i updated my question
    – Nick Kahn
    Sep 1, 2011 at 14:51
  • The path to the WSP needs to be in quotes if it contains spaces
    – Dave Wise
    Sep 1, 2011 at 14:55
  • okay... so i create a folder(c:\Deployment\MyFirstWebPart.wsp) on root without any space and i still get the error, i have updated my question.
    – Nick Kahn
    Sep 1, 2011 at 15:06

1 Answer 1

2

You would follow the standard deployment steps used for all Sharepoint WSPs. Copy the WSP to the file system of one of the servers in the farm, then open the SharePoint Management Console and execute the commands below. You will have to tailor the commands to fit your environment

Add-SPSolution fullpathtoWSP
Install-SPSolution –Identity NameOfWSP –WebApplication http://WebAppurl -GACDeployment

(give it time to deploy across the farm - you can check this status in Central Admin)

Enable-SPFeature -Identity "FeatureName" -Url http://SiteOrWebUrlForFeature
7
  • ` Copy the WSP to the file system of one of the servers in the farm` what does server farm means? is that a location where i need to copy? - i am new to SP
    – Nick Kahn
    Sep 1, 2011 at 14:30
  • Use whatever mechanisms you have at your disposal in order to copy the WSP file from your development machine to a windows folder on one of the machines that is part of the SharePoint farm that you want to deploy it to. If you are using Remote Desktop, then you can literally copy from the dev machine, open Windows Explorer on the server and paste it into the folder on the server.
    – Dave Wise
    Sep 1, 2011 at 14:36
  • thanks Dave, but my question what location do you want me to copy to? i will be copying from my local machine to VM machine and i am not sure what location should i copy to.
    – Nick Kahn
    Sep 1, 2011 at 14:38
  • The location doesn't matter other than you will need to provide that path in your Add-SPSolution command
    – Dave Wise
    Sep 1, 2011 at 14:39
  • paste it into the folder on the server which folder/location should i copy
    – Nick Kahn
    Sep 1, 2011 at 14:39

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.