Friday, February 1, 2013

Comments Rendering Issue in Sharepoint

I was working on a custom SharePoint master page, few days ago. After deploying the master page in Gallery, I set it for my site-collection. I had started facing a strange error i..e master tag is already defined. Initially I thought, that SharePoint existing pages, inherited from some other master page and I might override  it, but it also didn't work.

After some time, I started looking my master page html, I had a commented master tag, which I believe should not be rendered by SharePoint, as commented. I removed the commented tag for testing purpose, and surprisingly things starts working. SharePoint engine actually render the commented tag as well.

I hope this post will help any newbie in SharePoint world..... Happy Coding.....:)

Thursday, January 24, 2013

Generating Public key token


Many times we need to get the Public key token for a strongly named assembly in .NET.  “how to get the public key token?”. Answer is very simple use the .NET Framework tools sn.exe. So open the Visual Studio 2008 Command Prompt and then point to the dll’s folder you want to get the public key,

I have used the following command, for generating public key token for a SharePoint project
sn.exe –T SPExcercise1.dll
Public key token is d95388ccbe5ad4c1
This will give you the public key token. 
Remember one thing this only works if the assembly has to be strongly signed.

Monday, January 21, 2013

soap:ServerServer was unable to process request. ---> Value does not fall within the expected range.


In some odd situation, SharePoint Designer (SPD) 2010 would throw this error:
“soap:Server was unable to process request. Value does not fall within the expected range”
Cause
SPD does not open the site with name it was originally defined.  For example, the site was created as http://xyzmachine:9999/, but SPD connects it as http://localhost:9999/
Solution
SPD should connect the site with name/url defined at its creation.

Wednesday, October 17, 2012

Microsoft.WindowsAzure.ServiceRuntime.RoleEnvironmentException


Few days ago, I was working on a Windows Azure App, I created a Web Role  which was representing my application interface. Its purpose was to upload images. I needed to generate thumbnails as well.I thought to delegate this responsibility to a Worker Role. 
My Web Role  add image to a Blob and add a message in queue as well for the worker role, so that it can read it and generate thumbnails for each queued image, later.
When I created a worker role and tried to access the storage account with my defined connection string, it started giving me RoleEnvironmentException , I set the connecting-string for the application so I thought it will work for both Web ad Worker Roles, but it was not the case.
For Windows Azure, we have to set connection string for every worker and web roles, independently. I hope this will help any new bee on Windows Azure. 
Thank You and Happy Coding.......
Earn Money ! Affiliate Program
Open Directory Project at dmoz.org