Could be an interesting hint for those using CSOM search API: why are some of the results not returned?
Is it trim duplicates setting? No.
Is it some wildcard settings of the result source? No.
If you do not set the row limit of the query, you will get by default only 50 items. However, you can increase it like that:
var query = new Microsoft.SharePoint.Client.Search.Query.KeywordQuery(searchContext);
Last line does the trick. Please note that – by default – 500 is the maximum value.
If you need to increase it, you can do it e.g. via Powershell for the entire search service application:
PS> $mySearchServiceApp = Get-SPEnterpriseSearchServiceApplication
PS> $mySearchServiceApp.MaxRowLimit = 2000
Hope it helps,
Some of Sharepoint developers might be familiar with this kind of message. It appears in the status bar of Internet Explorer when some action is executed. If the message disappears, fine, but what if it remains there and the desired behavior isn’t executed?
I was getting this “Please wait while scripts are loaded” message on a web part page with one particular web part, which had some custom verbs defined. Web part verbs are kind of menu items for a web part, that allow to perform some actions on it. For each verb, one can define server-side and client side action to be performed when the verb / menu item is clicked. And this client side code of the verb was the crux of the matter.
I replaced the string with an underscore and the problem was solved. At this time I thought that maybe the names or ID’s in aren’t allowed to contain characters like hyphen. But no, according to W3C, hyphens are allowed since they’re not the first character of ID or name. Probably Internet Explorer tries to evaluate the expression, treating the hyphen as a minus sign. And reaches a deadlock at some point (please wait while scripts are loaded…)
Hope this helps,
var myArray = new Array("string1", "string2", 123);
This works fine when we have more than one element of the array. However, when we want to declare an array with one element, and the element is of an integer type, we could encounter an odd behavior. The reason behind is that a following command:
var mySecondArray = new Array(12);
…initializes an array with twelve elements, which aren’t filled at this time. And not, as expected, a single-element one. So, in order to declare a single-element array with an integer value, let’s consider a following “workaround”:
var myThirdArray = new Array(1);
myThirdArray = 12;
Declaring an array with a length of 1 element, then assigning the value of the element by finding it by its index should solve the problem.