Saturday, August 30, 2008

Failed to extract the cab file in the solution error while deploying the .WSP file

I got a requirement to create a site definition from a site. I created a blank SharePoint site and applied all the customization required on top of the blank site,it involved mainly the SharePoint Designer customization, Master page changes and the customization related to List and document libraries.

Then i was using the SharePoint solution generator to create the soluction. It successfully created the solution and i was able to build the solution in Visual studio 2005. It didn't give any issue while creating the .wsp file too.

But the problem happened when i was trying to deploy the solution from visualStudio 2005 using the "Deploy solution" option. It failed and gave me an error Deploy failed: "Failed to extract the cab file in the solution"
I tried to add the solution using the stsadm.exe -o addsolution command but got the same result.

After some more investigation i found that the issue is becuase .wsp packages with the filenames containing special characters will give the mentioned error while adding the solution to the SharePoint solution store.

So, I verified my new site definition project files created by solution generator. As expected, it was because of a file i named it with special characters while customizing the site. I had named that file as Newform(backup).aspx that was the reason for the problem. I just renamed that file without special characters rebuilt the project again, then deployed the site definition using "deploy solution" option.

It worked fine.

Tuesday, August 26, 2008

Find SharePoint version number

I had to prepare a document mentioning the softwares installed in my development environment. I was able to find the version number of other softwares. But in sharepoint its not quite straight forward and need to follow the below steps to find the exact version number

1.Go to central admin
2.Click on the Operations tab
3.Click on "servers in form" option under Topology and Services section
4.It should display the list of servers available in that farm as well as the version number of MOSS installed on those servers.

Display site collection name in top navigation bar instead of the text "Home"

When we create a new site collection(team site), the top navigation bar of the site collection will show the "Home" text. Based on one of our requirement we need to display the site collection name instead of displaying "Home",similar to the subsites.

I was thinking like it may require share point desginer customization, but there is an easy way out...

we just need to activate the site collection feature "Office SharePoint Server Publishing Infrastructure". That is changing the "Home" text to the
name given in the "Title" field of the site collection.

Monday, August 25, 2008

MSDN Forum points

I was answering few posts in MSDN forums and wanted to see how the points recognition system works. But i couldn't see the points from the profile page (most of the people expect the points table here).

I tried few options available in the forum and found that the points can be seen by clicking the "Browse user" button.

So, if you have done some contribution in MSDN forums, just click the "Browse user" button. Type the user name in the search box and search. It will show the points.

To know about how the points are calculated..refer the below Microsoft link
http://forums.msdn.microsoft.com/en-US/help#310

Tuesday, August 12, 2008

Disabling MySite option or Restricting it for specific users

Based on our project design, there won't be any personalization features for the users. I was checking with the various options available in Central admin and Shared service provider, here is the settings for doing that.

We need the administrator login to do the below settings changes.

1. Login to the central admin
2. Select the appropriate Shared Service Provider from the Left navigator
3. Click on the "Personalization services permission" link under the "User Profiles and MySites" section
4. Select the Group Name which contains the users to be restricted for "MySite" option, most probably this should be NT AUTHORITY\Authenticated Users and click on "Modify Permissions of Selected Users"
5. UnCheck the "Create Personal Site" Option (For disabling MySite)
6. UnCheck the "User Personal features" Option (For disabling MyLinks)
7. Click on the Save Button.

If you would like to give the MySite option to specific users follow the below steps,

1. Make sure the users need "MySite" option are organized via a active directory group.
2. Select the "Personalization services permission" link under the "User Profiles and MySites" section.
3. Click on the Add Users/Groups
4. Give the active directory group Name

Note:
  • We can also add User Names here but its not going to be scalable and will not be a good design.
  • Usually in a MOSS project the authorization part is done based on SharePoint Security groups, In most of the cases these groups will be mapped with an active directory account group.So we can easily select a share point security group to fit with this requirement and give that group's active directory mapping here.
  • 5. Select the "Create Personal Site" Option (For disabling MySite)
    6. Select the "User Personal features" Option (For disabling MyLinks)
    7. Click on the Save Button.

    Wednesday, August 6, 2008

    'HTTP/1.1 503 Service Unavailable' Issue while opening /creating ASP.NET Projects

    I was trying to open a project which was included with an asp.net web service project in VS2005 but got the following error.


    "The Web server reported the following error while attempting to create or open the Web project located at the
    following URL 'http://localhost/vijayservice', ''HTTP/1.1 503 Service Unavailable'

    End up with the same error while trying create a new asp.net project too.

    I checked the below things and it was perfect.
  • Default site authentication settings
  • User rights of user Ids IWAM_[Machinename],IUSR_[Machinename]

  • Somehow got the clue from the following things and resolved the problem as per the further points
  • Found that the same project was opening in my virtual PC.
  • My IIS was even not able to open the http:\\localhost

  • There were new restrictions implemented about using internet in our company and based on that the network will block all the addresses if the URL don't have our company name. But it was not really possible in our development team and we got some special rights for using other sites, based on that a proxy script was given and configured in our IE as like below screenshot.


    It was required to access some other sites needed for developing projects like msdn.microsoft. This needs to be done every time we connect to this network freshly. The same script needs to be configured for accessing http:\\localhost and for all the ASP.NET stuff.

    So guys, if you face this problem any time further don't spend too much time on investigating it and just check your proxy settings immediately if it is perfect. Do check your Site authentication settings and the access rights of IWAM_[Machinename],IUSR_[Machinename] accounts. You can also try to register your ASP.NET using aspnet_regiis.exe

    Monday, August 4, 2008

    Enabling Clipboard sharing and Dynamic resizing in Virtual PC 2007

    When i was using my SPS2003 installed virtual machine, I was able to share my clipboard contents between Virtual Machine and host machine. And I was able to resize the Virtual Machine by dragging its windows to a specific size and double clicking its bottom corner, by doing this i was able to fit the virtual machine screen to the window size adjusted by drag and drop.

    But the above two options didn't work in the Virtual machine I got for MOSS. It was very inconvenient for me to work with out those options. i tried various things to set it correct..

    I found that these functionalities are part of Virtual Machine additions and confirmed it is installed in my Virtual PC. Based on Virtual PC Guy's(Ben Armstrong) one of the
    blog i got to know that "vmusrvc.exe" is the key component for these features. So to get the above two functionalities,i did the following..

    checked the registry entries and found the following entries. If there are no Registry entries for Virtual Machine additions might not be installed on the Virtual Machine.

    [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Run]
    "VMUserServices"="C:\WINDOWS\VMADD\VMUSrvc.exe"

    Also verified "VMUSrvc.exe" is available in the above location and confirmed it is running by task manager processes tab. but still i had no luck.

    Finally i was able to do it by closing the VMUSrvc.exe from task manager processes and restarting it from the location "C:\WINDOWS\VMADD\VMUSrvc.exe". A simple workaround resolved my long lasting issue and made me happy:)

    Saturday, August 2, 2008

    To enable sound in Virtual PC 2007

    I resolved this problem in my VirtualPC2007 by following the below steps. wdma_ctl.inf and ctlsb16.sys should resolve the problem. These files can be extracted from a Windows XP product CD.

    Insert the XP CD in host OS, then using CD--> Use Physical Drive option to access the CD Drive inside VPC.

    Create a folder named SoundBlaster16 in C: drive. Open the command prompt and give the following commands one by one after changing the CD drive appropriately. This will extract the required files to C:\SoundBlaster16
            expand d:\I386\driver.cab -F:ctlsb16.sys c:\SoundBlaster16 
    expand d:\I386\WDMA_ctl.IN_ C:\SoundBlaster16\wdma_ctl.inf
    Start-->Run and type "Compmgmt.msc." Go to Device Manager and select the problematic soundblaster16 audio device. Right click and select the update driver option.

    Choose "yes this time only option" and "Install from a list or specific location" option in the wizard.

    Browse and select the C:\soundblaster16 folder created newly. Press Next ignore if any warning messages. This will install the required drivers. Click on finish once the installation is completed.

    Go to start-->Settings-->control panel-->Sounds and Audio devices. Check the enable sound option. Restart the virtual machine.This will enable the audio. Check the "Place volume icon in the taskbar" option to get the sound icon in system tray.

    This resolves the problem in most of the virtual PCs with windows2003 server, however it was asking the following list of files when i was configuring sound in my virtual PC. This might be because i haven’t installed SP2 yet.
    [aec.sys,dmusic.sys,drmk.sys,drmkaud.sys,kmixer.sys,ks.sys,ksproxy.ax,ksuser.dll,portcls.sys,splitter.sys,swmidi.sy,sysaudio.sys,wdmaud.sys]

    It was also asking few other files, i was able to select those from C:\windows\system32\ and c:\windows\system32\drivers folder of the Virtual PC itself.

    These files also can be extracted from windows XP product CD using the following commands. Select these files from the SoundBlaster16 folder when the popup window asks for the file.
            expand d:\I386\sp2.cab -F:ksuser.dll c:\SoundBlaster16 
    expand d:\I386\sp2.cab -F:ksproxy.ax c:\SoundBlaster16
    expand d:\I386\sp2.cab -F:ks.sys c:\SoundBlaster16
    expand d:\I386\sp2.cab -F:drmk.sys c:\SoundBlaster16
    expand d:\I386\sp2.cab -F:portcls.sys c:\SoundBlaster16
    expand d:\i386\sp2.cab -F:WDMAUD.SYS C:\soundblaster16
    expand d:\i386\sp2.cab -F:sysaudio.SYS C:\soundblaster16
    expand d:\i386\sp2.cab -F:splitter.sys C:\soundblaster16
    expand d:\i386\sp2.cab -F:aec.sys C:\soundblaster16
    expand d:\i386\driver.cab -F:swmidi.sys C:\soundblaster16
    expand d:\i386\sp2.cab -F:dmusic.sys C:\soundblaster16
    expand d:\i386\sp2.cab -F:kmixer.sys C:\soundblaster16
    expand d:\i386\sp2.cab -F:drmkaud.sys C:\soundblaster16