将 Web 部件上传到 Sharepoint 2010
我制作了一个 Web 部件,并尝试将其上传到 Sharepoint Server 2010。我这样做了:
插入->网页部件 ->上传 Web 部件 ->找到wsp文件->上传
后我收到此消息
“您导入的文件无效。请验证该文件是否为 Web 部件描述文件(*.webpart 或 *.dwp)并且包含格式正确的 XML。”
我错过了哪一步?当我从 Visual Studio (F5) 调试时,它工作正常。
更新
命令为:
stsadm.exe -o addsolution -filename C:\ABSOLUTEPATH.wsp
http ://technet.microsoft.com/es-es/library/cc263162%28office.12%29.aspx
STSADM.EXE -o deploysolution -name NAMESOLUTION.wsp -immediate
-allowGacDeployment -url http://URLSERVER
http://technet.microsoft.com/es-es/library/cc262459%28office.12%29.aspx
I made a Webpart and I try to upload it to a Sharepoint Server 2010. I did this:
Insert -> Web Part -> Upload a Web Part -> Find the wsp file -> Upload
and I get this message
"The file you imported is not valid. Verify that the file is a Web Part description file (*.webpart or *.dwp) and that it contains well-formed XML."
What step I miss? When I debug from Visual Studio (F5) it works ok.
update
The commands are:
stsadm.exe -o addsolution -filename C:\ABSOLUTEPATH.wsp
http://technet.microsoft.com/es-es/library/cc263162%28office.12%29.aspx
STSADM.EXE -o deploysolution -name NAMESOLUTION.wsp -immediate
-allowGacDeployment -url http://URLSERVER
http://technet.microsoft.com/es-es/library/cc262459%28office.12%29.aspx
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
您尝试上传的文件是 SharePoint 解决方案包。您可以通过 stsadm 或 Web 前端之一的管理控制台上传它(假设它不是沙盒解决方案)。部署解决方案包后,将出现网站集范围内的功能,您可以激活该功能以使 Web 部件在您的网站集中可用。
如果它是沙盒解决方案,您可以通过网站操作(在网站集的根网站中)、网站设置、解决方案(在库下)上传它。在这种情况下,您不需要访问 Web 前端。
The file you are trying to upload is a SharePoint solution package. You can upload it (presuming it's not a sandboxed solution) via stsadm or the management console on one of your web front-ends. After deploying the solution package, a site collection scoped feature will be present that you can activate to make the webpart available in your site collection.
If it's a sandboxed solution, you can upload it via site actions (in the root site of your site collection), site settings, solutions (under galleries). In this case, you don't need access to the web front-end.
您
无法上传 WSP - 这是指 VS 中实际解决方案包的文件。正如它告诉您的那样,您需要上传 .webpart 或 .dwp 文件(应该在您的解决方案中的某个位置!)
希望这会有所帮助。
Greetings
You cannot upload a WSP - that is the file referring to the actual solution package in VS. You need to upload, as it is telling you, either a .webpart or .dwp file (which should be in your solution somewhere!)
Hope this helps.