Wednesday, May 2, 2018

SharePoint Content Query Webpart - UseCopyUtil

If you want to use UseCopyUtil true in CQWP

True

Please make sure the set false the following attribute

 False

Monday, July 18, 2016

JavaScript - Bind

function getCount() {
    return this.myCount++;
}


> var counter2 = getCount.bind({myCount:100});
undefined
> counter2()
100
> counter2()
101

JavaScript - Closure



mycount variable act as Global variable

function getCounter() {
   var myCount = 0;
   return function() {
        return myCount++;
    }
}

counter = getCounter();


> counter();
0
> counter();
1

JavaScript - Arguments

JavaScript function without defining parameters

function add() {
    var result = 0;
    for (var i = 0; i < arguments.length; i++) {
        result = result + arguments[i];
    }
    return result;
}


Result :
> add(3,7,8,10)
28

Thursday, July 14, 2016

What is the difference between div and span

div is block element.

span is same as div, except it is an inline.

Monday, October 31, 2011

SharePoint error messages: “Unknown Error”

thanks to http://mindsharpblogs.com/phil/archive/2007/11/17/3551.html

If you open the web.config of the site you’re experiencing the problem in (eg. c:\inetpub\wwwroot\wss\virtualdirectories\mysitename\web.config), and do a search for “CallStack” and toggle that element to “true”. Then, do a search for “customErrors” and toggle that element to “off”. Save the web.config file.
If you go back to your site and refresh the page, you should see the actual exception that was thrown and where it was thrown.
Lastly, if you did this change in production, you’ll want to change it back, but that probably goes without saying ;)