Hot answers tagged

3

I've not provided whole code but you can call cross site connection using JavaScript. Take a reference from below code: var crossSiteContext = new SP.ClientContext("http://url-of-another-siteCollection/"); var crossSiteWeb = crossSiteContext.get_web(); crossSiteContext.load(crossSiteWeb); crossSiteContext.executeQueryAsync(function(){ var ...


2

I tried your code and got an unknown error. So i tried removing each field in the LINQ query and I found the error is due to grup => grup.Owner. I have changed it to grup => grup.OwnerTitle and the code worked fine. Also for getting each property value of a group loop the group collection object and get its value as per below code. GroupCollection ...


1

For SharePoint Online / Office 365, you can use JSOM to make cross-site collection calls as long as the site collections are all in the same tenant. There are only two scenarios where you can make cross-site collection calls using the JavaScript Object Model in a SharePoint on-premises farm: Both site collections are located in the same web application ...


1

You can use below mentioned code to get the details version of specific item from SharePoint list using Client Object Model. using System; using System.Collections.Generic; using System.Linq; using System.Text; using Microsoft.SharePoint.Client; using System.Net; namespace AccessVersionItems { class Class1 { File file; ...


1

grup.Owner returns Principal object. so you can't load it using LINQ. You can load owner object for group inside foreach loop like this. ` GroupCollection collGroup = context.Web.SiteGroups; context.Load(collGroup); context.Load(collGroup, grups => grups.Include(grup => grup.Title, grup => grup.Description, grup => grup....


1

When doing a CAML query for the page web URL I use: var fieldsToRead = "<ViewFields>" + "<FieldRef Name='WebPage' />" + "</ViewFields>"; as my CAMLViewFields var web = ($(this).attr("ows_WebPage")); gets the URL for the page. $("#relatedTable").append("<tr>" + "<td>" + "<a href=" + web + ">" + name + "</a>" + "...



Only top voted, non community-wiki answers of a minimum length are eligible