Represents the context of an HTTP request in Microsoft SharePoint Foundation.

learn more… | top users | synonyms

2
votes
1answer
42 views

SPContext.Current is null in application page

I created a simple SharePoint solution and added one application page, in code behind I am not able to access SPContext.Current because it is returning null see below code using System; using ...
0
votes
1answer
36 views

Redirect in UserControl

I have an issue to redirect page on the page load of my user control For this i use string sRedirectionURL = "/mylist/forms/allitems.aspx"; SPUtility.Redirect(sRedirectionURL + Request.Url.Query, ...
0
votes
1answer
337 views

Sharepoint 2013 with custom webapi service

I want to add a custom webapi service to sharepoint 2013. What I did so far is Create the webapi application Added an application in IIS Imported the webapi application Tests are succesfull to get ...
0
votes
1answer
206 views

Get the title and/or link of the parent website in javascript in SP2013

Is it possible somehow in JavaScript to acquire the title and/or link of the parent of my current site? I know that I can create a client context with a specific URL, but is it possible to do this ...
1
vote
0answers
9 views

Example DataService (with EF) in SP2013

Does anyone have a good example how to create a (WCF) dataservice in SharePoint 2013, WITH the use of Entity Framework? I need to be able to retrieve the SPContext also, so I guess this will be a ...
1
vote
0answers
89 views

Update SP Item in Parallel.ForEach loop

I'm trying to update columns of a ListItem in sharepoint using the following code: ClientContext context = CreateClientContext(_siteUrl); SP.List list = GetList(listName, context); Uri baseUri = ...
1
vote
0answers
78 views

FormContext.FormMode == DISPLAY after calling Edit Item in custom list

In a custom webpart we check on PageLoad the SPContext.Current.FormContext.FormMode to show different additional controls on edit and display mode. If the list is created manually everything works ...
1
vote
0answers
107 views

SPContext.Current is null

I am making a call to a Web service on the initial load of the page through an Angular JS Service. The Web service calls a DLL where I am accessing SPContext.Current. If I am allowing the application ...
1
vote
0answers
638 views

Fake SPContext as a particular user

I am using this method of faking an SPContext: http://solutionizing.net/2009/02/16/faking-spcontext/ public static SPContext FakeSPContext(SPWeb contextWeb) { // Ensure HttpContext.Current if ...
0
votes
0answers
51 views

Get subsite context without username, pwd in provider hosted add-in

Below is my scenario in Page_Load: var spContext = SharePointContextProvider.Current.GetSharePointContext(Context); using (var clientContext = spContext.CreateUserClientContextForSPHost()) { ...
0
votes
0answers
70 views

SPServiceContext is null exception when I try to create result source in farm feature receiver

I created an feature farm scoped. In the eventreceiver of this feature I would like to create a new custom "result source". When I try to deploy I got an exception in VS: Value cannot be null. ...
0
votes
0answers
286 views

How to get Groups RoleAssignments with COM

I'm trying to retrieve Roles Assignments and SPRoleDefinitionBindingCollection from a Group .Probably, I'm using the wrong method to that. The RoleAssignment groupRoleAssignments = ...
0
votes
0answers
1k views

SP2013 - The object is used in the context different from the one associated with the object

I have a function that initializes a custom taxonomy control, as below (not in myControl.js) function initMyControl() { if (something is true) { var context = new ...
0
votes
0answers
22 views

Give site directly using client context

I have many sites in my site collection, and I am wanting to get the pages of one site. Is there anyway to give the site that you want the pages for? so like clientcontect.get_site('sitename')
0
votes
0answers
927 views

Problem with ASMX and SPContext.Current equals to null

I'm deploying my application to an Sharepoint Foundation Farm... In my application there is a web service (tt2sp.asmx) installed in the _vti_bin directory. On my site the anonymous access is ...