Friday, January 20, 2012

Editing contents of a WSP (SharePoint 2010)

In Solution file WSP in SharePoint 2010, you can see the contents of the WSP by changing the file extension to CAB. You can then open the file like a ZIP file within Windows Explorer, or via WinRAR.

But you cannot modify it using one of these items:

  • Creating a new archive file within Windows Explorer – and changing to CAB or WSP extension.
  • Trying to delete or drag into an archive shown in Windows Explorer.
  • Creating a new archive with WinRAR – and/or dragging into a CAB file using WinRAR.
  • Using MAKECAB.EXE to create an archive via command line is difficult.

I found tool (IZArc) solve this problem. Steps involved to update the WSP are as follows :

  1. Rename the WSP to CAB
  2. Extract all contents to a folder – using Windows Explorer, or WinZip, WinRAR, or whatever
  3. Change the items you want.
  4. Create a new CAB file with the updated contents, using IZARC. (IZARC support many types Archived type must be CAB and include subfolders)
  5. Rename the newly created CAB to WSP
  6. Install to SharePoint


No comments: