Skip to main content

The Execute method of job definition “SPSolutionDeploymentJobDefinition” threw an exception, Value cannot be null.

I have developed an Timer Job Definition,feature & feature receiver to create the timer job.

On WSP deployment on my local machine it install with no issue 🙂

Now when deploying on the WebFarm environment with a Front end server , I faced following error.

The Execute method of job definition “SPSolutionDeploymentJobDefinition” (id “030bb074-94a8-4f5d-bf34-b4ca735c1693”) threw an exception. Failed to create feature receiver object from assembly “Company.Project.Business, Version=1.0.0.0, Culture=neutral, PublicKeyToken=1f12345e9c67bc89”, type “Company.Project.Business.EventReceivers.MyTimerJobFeatureReceiver” for feature C0857DB8-1636-11E0-AC62-40DFDED72085: System.ArgumentNullException: Value cannot be null.
Parameter name: type
at System.Activator.CreateInstance(Type type, Boolean nonPublic)

at Microsoft.SharePoint.Administration.SPFeatureDefinition.get_ReceiverObject()

Initially I thought It is something wrong with the Event Receiver Class and the application could not find the class. Changed the scope of Class, changed the name of the class, restarted IIS, But I no result.

After two hours of troubleshooting, I restarted

Get PageLayout Name in Sharepoint but having a performance issue

I googled and found one of the easy way to get the PageLayoutName.

if (PublishingWeb.IsPublishingWeb(web))
{
PublishingWeb publishingWeb = PublishingWeb.GetPublishingWeb(web);
PublishingPageCollection publishingPages = publishingWeb.GetPublishingPages();
PublishingPage publishPage = null;
var spfile = SPContext.Current.File;
Guid id = spfile.UniqueId;
if (publishingPages[id] != null)
{
publishPage = PublishingPage.GetPublishingPage(publishingPages[id].ListItem);
currentPageLayout = publishPage.Layout.Name;
if (currentPageLayout.EndsWith(".aspx"))
{
currentPageLayout = currentPageLayout.Substring(0, currentPageLayout.Length - 5);
}
}
}

The above code is having a heavy performance issue as I am getting all the PublishingPages and searching is in Pages.

One of the already ways is to use CAML Query in

SharePoint/MOSS Enter Key On Search Box Not Working In Firefox

I cam across a strange situation where the page of my SharePoint website just refreshes itself when I search on my site using the Enter key. I noticed this was only a problem when I use Firefox.

On Goggling I found following solutions

http://social.msdn.microsoft.com/Forums/en-US/sharepointecm/thread/87574c13-91d6-48fe-8346-01e77e0094b3

http://blog.drisgill.com/2009/08/firefox-doesnt-respond-to-enter-key-in.html

http://blogs.msdn.com/b/jjameson/archive/2009/10/01/enter-key-does-not-submit-search-in-moss-2007-from-firefox.aspx
I modified the solution by Jeremy Jameson, to suit my requirements.

    <script language="javascript"> function replaceOnKeyPress()
    {
    var theInputID = $("input[name$='InputKeywords']").attr("id");
    if(typeof(theInputID) != "undefined")
    {
    var theFunction=theInputID.replace("InputKeywords", "");
    var LastindextOf =theFunction.lastIndexOf("");
    if (LastindextOf >0)
    {
    theFunction=theFunction.substring(LastindextOf+1,theFunction.length);
    theFunction = theFunction + "_Submit();";
    var txt = document.getElementById(theInputID);
    var browser = navigator.appName;
    if (txt && (browser == "Netscape"))
    {
    txt.onkeypress = function(e)
    {
    var key = String.fromCharCode(e.keyCode);
    if (key == "\n" || key == "\r")
    {
    eval(theFunction);
    return false;
    }
    }
    }
    }
    }
    }
    replaceOnKeyPress();
    </script>

Extending Microsoft Commerce Server 2009 web part extensibility kit for SharePoint 2007

I found this article is very useful to Extends Out Of Box(OOB ) commerce server 2009 extensibility kit. It will take less then 10 minutes time to extend.

Original Source : http://blogs.msdn.com/commerce/archive/2010/04/21/using-microsoft-commerce-server-2009-web-part-extensibility-kit-for-sharepoint-2007-effectively.aspx

Full credit and Thanks to matin.larijani

Note: Creation of our own namespaces is not cover in this article.

Here you go.

If you have worked with a Commerce Server 2009 SharePoint site (Default Site aka Template Pack) you have probably noticed that the quickest and most efficient way of re-skinning this site is to create new XSLT templates for XSLT Web Parts and manipulating the style sheets (CSS) using SharePoint Designer. Using these tools will give you the ability to leverage the Content Management capability of Microsoft Office SharePoint Server 2007 to manage changes in your SharePoint site

Custom SharePoint 404 page works in IE but shows HTML tags in Firefox

A strange thing I noticed is My404Page was not working properly on Firefox, I then tested it on IE and it worked.

When I browse my website it shows the HTML tags on the page.

clip_image002

When I test the site using https://dewani.net/123.aspx My custom 404 page showed up correctly

When I test the site using https://dewani.net/123 My custom 404 page showed up HTML tags.

When I digging and goggling I found it

Commerce Server 2009 Developer Training November 3- 5th, 2009

Cactus Commerce has added a second Commerce Server 2009 Developer Training course for partners, customers and Microsoft field November 3 – 5th, 2009 in Gatineau Quebec, Canada.

The 3-day Microsoft Commerce Server 2009 Developer Training course is designed with ASP.Net developers in mind. Students will learn the why, what and how of working with Commerce Server 2009 in a balanced format of ‘presentation, discussion and hands-on labs’. On completion of the course, students will have the knowledge to develop e-commerce solutions using the Commerce Server 2009 platform.

Commerce Server 2009 Training Curriculum: