vendredi 27 mars 2015

How to set documenttemplate using powershell

How could i set this using powershell? $dst = [Microsoft.Office.DocumentManagement.DocumentSets.$dst.Update($true)]::GetDocumentSetTemplate("/_layouts/CreatePage.aspx")


SharePoint 2013 document generation - error cant open document

Im trying to use a document lib to generate documents.I have created 6 content types(as I need multiple templates) and associated doc templates to them. I read somewhere I should be using .docx instead of dotx as a template

But cant get it to work arg!!! enter image description here

jeudi 26 mars 2015

Events/Changelogs in the new Office365 Files API

I'd like to know if this new Office 365 API provides changelogs for diff events that occur on OneDrive for a tenant user like Share, Unshare, Create Update, Delete events etc.

Much appreciated!

SSRS report from SharePoint list

We have created an SSRS report from SharePoint 2010 list. We have item level permission in the source list, so the user can view only the items for which they have privilege. But in SSRS report it picks all records without filtering out using access privilege.

Is there any option in SSRS to filtering out data using access privilege of current user? If not could you explain why?

How to check one user's permissions for the root site and all the subsites?

we are using O365/SharePoint Online 2013.

Is there any way to check a specific user's permissions for the root site in question and all of its subsites so basically all sites in a site collection? We have 10 subsites and some users can access a few of them and some might have the access to every one of them.

From time to time I get asked to check where one specific user has access to and at the moment the only way I have found is to check the user permissions one site at a time. That is quite time-consuming, so is there any easy/quick way to see all the sites a user has access to?

I greatly appreciate any information regarding this matter!

How to lock certain rows in sharepoint web access list?

How to lock certain rows in sharepoint web access list? It would be useful to lock the rows whichever is completed and to eliminate the further updating.


How to find out missing or deleted site collections in Staging Environment

We have created some 40+ site collections in staging environment.On the dev machines we used to development and deploy the wsps and run the powershell scripts in UAT to create site collections and sites.Yesterday when we started doing normal testing of our portal,we found that ROOT site colelction and another important site collection were missing.I checked the event viewer logs information in the UAT box.But did not find anything mysterious.Can anyone help how to find out why this happened?This happened within 12 hrs of time.If I enable Auditing on this SP Farm, will it help me to find what happened on those sites.I checked the content database of one missing sitecollection.Its intact.Later customer reported us that they faced some issues in their SAN storage environment.I am not able to find the link between these two.

Upload list item attachment using JSOM

I am trying to upload list item attachment using the below code. There is no error in the code and all the variables are present with proper values but in uploadFile method it goes to error handler and says File not found. Can anyone help?

function UploadAttachment() {
this.filename = $('input[type=file]').val().split('\\').pop();
var args = window.frameElement.dialogArgs;
this.itemId = args.ItemId; //$.QueryString["ItemId"];
this.clientContext = new SP.ClientContext.get_current();
var outReachList = clientContext.get_web().get_lists().getByTitle('Outreach List');
this.listItem = outReachList.getItemById(itemId);
clientContext.executeQueryAsync(Function.createDelegate(this, this.HasListItemAttachment), Function.createDelegate(this, this.GetAllAttachmentsFailed));

function HasListItemAttachment() {
var attachmentFolderUrl = String.format('{0}/Attachments/{1}',listItem.get_fieldValues()['FileDirRef'], itemId);
this.attachmentFolder = clientContext.get_web().getFolderByServerRelativeUrl(attachmentFolderUrl);
clientContext.executeQueryAsync(Function.createDelegate(this, this.uploadFile), Function.createDelegate(this, GetAllAttachmentsFailed));

//function to actually upload file
function uploadFile() {
var file = document.getElementById("customFileUploadControl").files[0];
getFileBuffer(file).then( function(buffer) {
var bytes = new Uint8Array(buffer);
var content = new SP.Base64EncodedByteArray(); //base64 encoding
for (var b = 0; b < bytes.length; b++) {
var createInfo = new SP.FileCreationInformation();
createInfo.set_content(content); //setting the content of the new file
clientContext.executeQueryAsync(Function.createDelegate(this, uploadFileSuccess), Function.createDelegate(this, GetAllAttachmentsFailed));

function uploadFileSuccess() {

function GetAllAttachmentsFailed(sender, args) {
console.log('Request failed. ' + args.get_message() + '\n' + args.get_stackTrace());

function getFileBuffer(file){
var deferred = $.Deferred();
var reader = new FileReader();
reader.onload = function(e){
reader.onerror = function(e){
return deferred.promise();

SharePoint paging control always show 1-30 even there are 400 items

On our SP2013 on-premise farm there is a document library contains around 400 items. All these 400 items have individual permission (inheritance are broken).

If I open the libaray with All Site Content > Doc Library, the paging control is working as expected.

On one of page we have insert the Doc Libary as App. On that view the paging control always showing "1-30 >". When user click on ">" the page have changed but the control still show "1-30 >". Hence, user cannot switch to left page and cannot know the total number of items in libaray.

Is it known bug and can I work around it?

Help! Sharepoint library template broken after replacing

I Went in and changed a sharepoint template (*.xsn) which was being used by a document library to create and modify new items.

I thought the safe way would be to rename my new one over the top of the old...but now it won't allow me to create new items or open old ones in the library.

If I try to open an old library item now it attempts to open infopath and then complains about a domain permission level problem.

How do I link it the library all back to the new template correctly?

Is it possible to update a VS deployed app without changing app's URL?

I'm building a SharePoint hosted app which for now I'm deploying from VS. Every time I redeploy the changes, it completely reinstalls the app also changing its URL (the unique identifier part of it) which means I also need to change IIS bindings (my dev box doesn't have a DNS server) and some client side code every time as well.

Is there any way to update the app without changing its URL?

Cannot query SP.UserProfiles.PeopleManager from the App Web via REST

I'm testing REST results in the browser with mixed results.

The following URL returns the expected result:

however the following URL returns an error:

I get the error code -1, Microsoft.SharePoint.Client.ResourceNotFoundException and error message Cannot find resource for the request sp.userprofiles.peoplemanager. Google doesn't offer up much for the errors. Fiddler responds with a 404 result. I've tried leaving the URL unencoded, tried with lower case sp.userprofiles.peoplemanager and getuserprofilepropertyfor with no luck whatsover. I have also tried other methods within sp.userprofiles.peoplemanager. What am I doing wrong?

Field Labels in InfoPath?

Seems like a really simple question but I can't find anything about how to add labels to InfoPath fields?

I just want a text label beside a checkbox for example.

I know I can just type the text in beside the checkbox, but I would prefer to have an assigned label.

Surely this functionality exists?


script in powershell to create a list and add a lookup column

Script to create a custom list and add a look up column into it and add the column into a default view. The look up column should have relationship of Restrict delete.

Need to stop Sharepoint from batching separate requests into single correlation id

I have an installation of Sharepoint 2013 which has a site with a custom full-trust Sharepoint solution web part installed on the main page. This custom web part does extension logging within ULS including start and end times of process execution for all of its custom routines. Under light load this web part performs well. The problem is that under moderate load of 50-250 concurrent users this web part experiences slow page loads of around 60 seconds in some cases. The Sharepoint farm is built to spec according to Microsoft’s recommended practices. Within SolarWinds monitoring we see that the Sharepoint farm’s hardware is not being strained. While investigating the problem I was surprised to find within the Sharepoint Web Front End ULS that Sharepoint appears to be batching separate user requests into a single Correlation Id. I can see this because every time I log to ULS within my custom code that I include the user's login id. The sizes of these batches vary. Some may have two separate user requests within them. Others can have up to 7 separate user requests. Furthermore what I see is that within the batch that there is significant delay in between processing of transactions within the batch. In some cases there can be 10 seconds of delay before the next user's transaction within the batch executes. I have analyzed the ULS logs and from what I have seen the custom code transactions typically execute within fractions of seconds. But the delay in between custom code transactions within the correlation id batch cause a lot of delay. How can I stop Sharepoint from batching separate requests in this way? Is there a configuration setting that can be set to stop this behavior?

Open Excel file in browser returns error

I have configured an excel document library to open in the browser.

The file was published to the document library.

The document library was set to open the file in the browser.

When the file is clicked, it makes an attempt to open the file in the browser but it returns an error message.

Unable to process the request.

Wait a few minutes and try performing this operation again.

What else is necessary to get the Excel file to open in the browser?Excel Open In Browser Error Message

Filter on Views don't work after update 2956175 is applied on SP2013 env

We have applied Filter on a task list view on the Assigned To column. This was working fine. Last friday we installed the Security patches available from Microsoft published on 3/10/15. Immediately we say that the filters were no longer working. Additional filters on Dates and Number fields also failed to work.

Has anybody faced this issue already? Was it resolved? How?

Is there a work around or a way to uninstall the KB security update?

Web Part Connection to multiple lists on web part page

I have a Web Part Page with multiple lists displayed on the page. All lists have a common column named 'Product'. I want to filer all web parts by the 'Product' field, using web part connections. I'm using the Product master list and connecting to all the other lists with the same column name. I want the user to select a Product via the built in list search, then click the web part connection selection icon to filter all the other lists. This is all working fine, except when the page reloads/refreshes to display the filtered result the master list refreshes back to the first item in the list. So, the child lists display the correct filtered values, but the master list reverts back to the first item. Is there a workaround for this? Or, a better option? Just to add, I have over 700 products in the list, so a list filter isn't an option. Thanks.

SharePoint redirects me to non-existent Account/Login page

I'm running into a weird situation. I have two web applications, both using Windows Authentication. They are both using the default login page, both disallow anonymous access, no other special configuration.

Both site collections are publishing sites.

When I navigate to Web Application 1 (port 80), after logging in, I see the landing page for the site collection, and everything works as expected.

When I navigate to Web Application 2 (port 81), after logging in, SharePoint tries to redirect me to [MySiteUrl]/Account/Login. There is no such page, or configuration that I am aware where this is specified. Because the page cannot be found, it directs me to the PageNotFoundError screen. Oddly enough, I am authenticated, so clicking "go to the site home" link does take me back to the home page.

enter image description here

The situation happens when accessing it internally on the server, or externally, so I don't think it's related to Access Mappings.

This is a fresh install of SharePoint, so I'm not really sure what could be the problem.

How can I get a list of all site urls, site titles, and their site owners through powershell?

I've been able to get the following:

Get-SPSite -Limit All |
Get-SPWeb -Limit All |
where { $_.HasUniquePerm -and $_.AssociatedOwnerGroup -ne $null } |
foreach {
$url = $_.Url; $_ } |
Select -ExpandProperty AssociatedOwnerGroup |
Select -ExpandProperty Users |
Select {$url}, UserLogin, DisplayName | Export-csv c:\test.csv -notypeinformation

This gives me the site url, site owner's logins and display names. However, I can't figure out how to also get the site title. I seem restricted to either getting the title or the url of a site. How can I pull back both through this method?

Feature-Site Theme activation leads to error

When I click on the site collection features>Activate(Theme) it is leading to this error. This is happening when I click on site Actions>Create new site and selecting blog under sites and workspaces. Please help me with troubleshooting this.I have done some research and saw that some DLLs might be missing or some references are not working properly.

Feature '9aafa318-8619-4726-8531-660edf9221ff' could not be installed because the loading of event receiver assembly "DCCTheme, Version=, Culture=neutral, PublicKeyToken=43bbb856e4d7825b" failed: System.IO.FileNotFoundException: Could not load file or assembly 'DCCTheme, Version=, Culture=neutral, PublicKeyToken=43bbb856e4d7825b' or one of its dependencies. The system cannot find the file specified.
File name: 'DCCTheme, Version=, Culture=neutral, PublicKeyToken=43bbb856e4d7825b'
at System.Reflection.Assembly._nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, Assembly locationHint, StackCrawlMark& stackMark, Boolean throwOnFileNotFound, Boolean forIntrospection)
at System.Reflection.Assembly.InternalLoad(AssemblyName assemblyRef, Evidence assemblySecurity, StackCrawlMark& stackMark, Boolean forIntrospection)
at System.Reflection.Assembly.InternalLoad(String assemblyString, Evidence assemblySecurity, StackCrawlMark& stackMark, Boolean forIntrospection)
at System.Reflection.Assembly.Load(String assemblyString)
at Microsoft.SharePoint.Administration.SPFeatureDefinition.get_ReceiverObject()

WRN: Assembly binding logging is turned OFF.
To enable assembly bind failure logging, set the registry value [HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1.
Note: There is some performance penalty associated with assembly bind failure logging.
To turn this feature off, remove the registry value [HKLM\Software\Microsoft\Fusion!EnableLog].

Troubleshoot issues with Windows SharePoint Services.

New Update : This error is only happening with few new servers. This used to work fine before in the old windows server 2003. So the conclusion is it is server specific.Now how do I make it work in the new servers?

What is the best way to search a sharepoint 2013 list with more than 5k items?

We are migrating content from SP 2007 to SP 2013. We have many lists that have more than 5k items... some of which we need to be able to search all items. If we use the "find an item" search it only searches the items in that view (<5k) and the user experience is not good. The only wany we can figure out how to search all items is using the new Content Search web part, which is not the easiest to configure and the OOTB display templates aren't very good.

Before I start creating a bunch of Content Search web parts and custom display templates I would like to know if we are headed in the right direction? is there a different, better way to be able to search all items in a list?

Thanks! MP

Rich text box is distorted

enter image description here

Hi All

After migration from MOSS 2007 to SP 2010, In a list, Multi line Rich text box is distorted, its tool bar is showing large images, please see attachment and give a suggestion to resolve this issue.

Thanks in Advance

Profile Sync is running but it does not update the attributes correctly

We have SharePoint 2013 with September CU (15.0.4649.1000) and we have started to receive issues when users change their manager or work status and in SharePoint it does not update the attributes that it sync from AD. I ran the profile sync and it completes, but we still have the issue even after doing several Full Imports.

I see the following errors in the Application log:

Log Name: Application Source: FIMSynchronizationService Date: 2015-03-23 7:43:58 AM Event ID: 6803 Task Category: Management Agent Run Profile Level: Error Keywords: Classic User: N/A Computer: Description: The management agent "MOSS-UserProfile" failed on run profile "MOSS_FULLIMPORT_cb726a76-3e22-472d-87d6-10ecfaac0a01" because the server encountered errors.

Log Name: Application Source: FIMSynchronizationService Date: 2015-03-23 7:43:58 AM Event ID: 6801 Task Category: Server Level: Error Keywords: Classic User: N/A Computer: Description: The extensible extension returned an unsupported error. The stack trace is:

"System.Net.WebException: The underlying connection was closed: An unexpected error occurred on a receive. ---> System.IO.IOException: Unable to read data from the transport connection: An existing connection was forcibly closed by the remote host. ---> System.Net.Sockets.SocketException: An existing connection was forcibly closed by the remote host at System.Net.Sockets.NetworkStream.Read(Byte[] buffer, Int32 offset, Int32 size) --- End of inner exception stack trace --- at System.Net.Sockets.NetworkStream.Read(Byte[] buffer, Int32 offset, Int32 size) at System.Net.PooledStream.Read(Byte[] buffer, Int32 offset, Int32 size) at System.Net.Connection.SyncRead(HttpWebRequest request, Boolean userRetrievedStream, Boolean probeRead) --- End of inner exception stack trace --- at System.Net.WebClient.DownloadDataInternal(Uri address, WebRequest& request) at System.Net.WebClient.DownloadData(Uri address) at Microsoft.Office.Server.UserProfiles.ManagementAgent.ProfileImportExportExtension.DownloadPictures(ProfileChangeData[] profiles, Boolean delayErrors) at Microsoft.Office.Server.UserProfiles.ManagementAgent.ProfileImportExportExtension.Microsoft.MetadirectoryServices.IMAExtensibleFileImport.GenerateImportFile(String fileName, String connectTo, String user, String password, ConfigParameterCollection configParameters, Boolean fFullImport, TypeDescriptionCollection types, String& customData) Forefront Identity Manager 4.0.2450.51"

Also, Checked Synchronization Service Manager and we got status: stopped-extension-dll-exception

Found the following relevant blogs:


I am thinking of running PS script as described in above Blog (the last link) and not sure if this has any ramifications or whether it will fix the issue that we are having with AD attributes not updating correctly.

Also, another colleague of mine pointed out the following Blog: But we are not using AD Connector but FIM, and was wondering if updating to October CU would fix the issue since this is happening in our environment where some users who updated their profile in AD see their assistant as their managers and their managers as assistant, but also in our environment we see other AD attributes are affected.

I also, would like to mention the following settings in our environment: 1. We are not using Picture Property name and it is not mapped.

enter image description here

  1. We created a new managed property for the user photo and it is mapped an AD attribute

SharePoint 2010 - Can I get access to Version History tables?

I need to be able to produce a report to show the version history records for my SP databases. I imagine that I can access the SQL tables where the information is held, and pull out the version history records for reporting. Can someone advise me on how I might be able to do this by directly access the version history records for an entire database, not just one record at a time?

SPF2010: Using a lookup for a default value

I have two lists: one is a list of customers, and one is a list of service calls.

The customer list has [Driving Distance], which is the distance from our central office to their office; likewise, the service call list has [Travel Start Time] and [Mileage] for our employees to document their travel.

Now, here's my idea: when an employee creates a new service call, if they had to travel, take a guess at the mileage. I've already tried setting [Mileage]'s default value to this calculated formula:

=IF(ISBLANK([Travel Start Time]),
[Client:Driving Distance]

However, SharePoint just threw an error back at me, saying that [Client:Driving Distance] didn't exist. (I know it exists, but I guess I can't use it in a calculated column.)

Is there any way to implement my idea? If SPF2010 has a JSON API, I'm not familiar with it.

Uncheck "Overwrite existing files" on default when uploading file

Currently when users want to insert an image inside the rich text editor, they will be prompted with the following: enter image description here

How can I make it so the overwrite box is unchecked on default, and the Destination is automatically pointing to "Documents"?

Audit Logs for Documents, Hits Not Registered On View

SharePoint 2013 Standard. View logs are not always registered in the AuditData table for document files.

Auditing at a site-level and item-level both enabled.

If I open a PDF file in a browser, and hold F5 for a few seconds, only then a few entries will be added to the table.

Any help please?

Upgrading sharepoint 2007 to 2013

We have a sharepoint 2007 site with some custom coding as a solution and web parts, now I want to upgrade that site to sharepoint 2013. I have read about Avepoint tool, which migration tools do you suggest? how can I found out how much coding customization do we have on our current 2007 site.

Optional Comments Underneath a Survey Question

What are the steps/processes in order to be able to edit a survey page to allow optional comments underneath each question?

I would like the user to select a radio button titled "Comment?" and from there on pops up a textbox to be able to comment on the question asked. It doesn't even HAVE to be a radio button.

Also, how do I get it to push the data over to responses. It should then show up in the response view. Someone please help.


Execute file Javascript with Powershell

I would like to schedule a script powershell that runs a js file, someone has an idea to realize it?

I use Sharepoint 2013 Online.

Thank you for your help

how can I sandbox user areas?

What if I was to create a SP2013 document library that contains one folder for every user? Users can only view and edit their own folders. The idea is that every user would have their own sandbox area/folder.

The problem is that there are 700+ users. So that’d be 700+ folders.

Are folders the right approach here?


Permission user from different forest

A power user recently asked me a question whether or not he can share a site with someone whose account is in a different forest. Obviously he could not find that user through 'Select People and Groups' dialog. As he is not a farm administrator he can't change the PeoplePicker SearchADForest property either.

5000 item limit prevents opening item even if view works fine

I have a Sharepoint task list with 5001 items in it. I have talked with the department that uses it about limiting the size by clearing out old items, but that is probably a little ways off.

When I ran into the size limit, I increased the limit temporarily and added an index and then brought it back down to 5000. That worked fine to allow me to view the list. However, I could not open an item from the list to edit it unless the view threshold was brought back up above 5000.

What is the solution for this?

I should say that this particular list is used by about 10-15 people at a time, max.

LDAP query not working in custom web part

I have a custom web part which will pull Active directories custom attribute(logged in user). For testing purpose currently I am trying to get "mail" of currently logged in user. But it is not working. Here is my code

DirectoryEntry entry = new DirectoryEntry("LDAP://");
DirectorySearcher mySearcher = new DirectorySearcher(entry, "(sAMAccountName=myuserid1)", new string[] { "mail" });
SearchResult result = mySearcher.FindOne();
if (result != null)
mailID = result.GetDirectoryEntry().Properties["mail"].Value.ToString();

The same code works perfectly in "Windows form". I have been fighting with this code. Please suggest some ideas. Appreciate your help.

Hiding the Survey List from browser in Sharepoint 2013

Every time I try to hide the Survey list from browser in Sharepoint Designer 2013 I receive an error telling me I couldn't. I am able to hide other kinds of list, besides that one.

enter image description here

Today, I have to run a script to hide it. I would like to do it using the Sharepoint Designer, instead.

Getting List Column Order

I'm using the SharePoint 2013 JavaScript APIs, calling web.get_lists().getByTitle('ListTitle') and then list.get_fields() to create a custom search panel. However, the fields do not come back based on the column ordering set in the list settings. Is there a way to get to the column order value via JavaScript? I've seen examples for setting, but none for reading it. Thanks in advance for your help.

Pasting excel rich text column into Sharepoint 2013 list edit view

I was trying to paste an excel table to SP2013 datasheet view with one of the column is enhanced rich text editor. But the view stripped out the styling from excel table.

Excel table: Excel table

This is the result of the pasted text: SP List view

Any thoughts on this guys?


How do you associate a workflow with a list in SharePoint 2013?

I have been migrating a list with ShareGate. The list's workflows were modified on the destination, but for the sake of quickness I deleted the list before I re-migrated it.

The workflow for the list remained intact; however, there was no way to associate the list with the workflow, or to associate the workflow with the list. The workflow is now freestanding; it refuses to associate with a new list because it wasn't designed as a re-usable workflow.

I've seen suggestions on using Visio 2013 Premium to convert the workflow between types, but I don't have that program right now.

Missing Site Collection Features

I'm having trouble with mirgrating a subsite template to a new sharepoint site. When I try to create the new subsite, I get a list of required features that I cannot find on the site collection features list. (I've already tried activating all the features but only a few of the required features have been solved).

Usually, when I try to make a new subsite with a template, I can ignore the required features, but this time I'm not getting the option. Plus I've also tried downloading sharepoint powershell but I need a licence to use it. Any helpful advice?

How do I remove a site when the remove-spsite returns "object reference not set to an instance of an object" error

I have a 2010 SharePoint farm with 5 site collections. Because we're using TFS with multiple team project collections in the 2010 farm, I need to take a phased migration approach to move the content from the 2010 farm to the 2013 farm.

Because we're taking a phased migration approach, we will need to upgrade the content several times. SharePoint 2013 won't allow me to upgrade a site collection more than once. If I do, I get this error:

Site <url> cannot be upgraded

I get this error because the site collection's GUID exists in the database. It exists even if I delete the site collection in Central Administration.

A bit of googling suggests that I should use PowerShell to do this. So I attempted to do that:

remove-spsite -identity "<guid>"

returns the error:

Object reference not set to an instance of an object.

More googling suggests using a force option to delete. It fails with the same error.

If I query the SiteMap table in the SharePoint_Config database, I can see the GUID for the site in this table, but I'm reluctant to delete it using SQL for fear that I may create more orphans in the database.

Does anyone know how to fix this using a Microsoft released utility?

Install active directory after SP Farm installation

I have installed a SP2013 Farm everything works. Now for some reasons I need to install AD domain controller. Could this cause any problems to the FARM? What should I do before this operation to ensure functionality after?

LightSwitch app on SharePoint Server 2013

So here's the problem: I have a simple Lightswitch app made with VS 2013. I am DB-admin and SharePoint has the default settings.

When I click "deploy", VS is installing exactly 38 minutes and then it asks me if I trust this app. When I click Yes, Internet Explorer shows "Sorry, something went wrong" but no details...

another deploying error is this one: "Web deployment task failed. (Object of type 'manifest' and path 'C:\Users\kmartini\documents\visual studio 2013\Projects\SurveyApp\SurveyApp\SurveyApp.SharePoint\bin\Debug\app.publish\\SurveyApp.SharePoint.Web.SourceManifest.xml' cannot be created. Learn more at:"

So what is the problem here?

Remove the numeric from a managed metadata term referenced in a workflow

Using SP 2010 Ent and SPD can I remove the long number after the term in my workflow i.e. when outputted to an email? Thanks

How to rename an SPFolder

In an event receiver, in itemcreated and not creating, i need to rename the spfolder created. I've tried with meta Name or FileLeafRef but no one works

properties.item["Name"] = "new name";

Ho to achieve this

How to Create a Rotating Work Schedule Calendar/O365/best method

I have been tasked with creating a shared calendar for a department to view employee work schedules (schedule A and Schedule B(. The employees work a rotating schedule that changes every three months with days varying based on which schedule they are on and is a combination of 3 days on 2 days off, 2 days on with 3 days off, etc.. Can anyone suggest the best method for accomplishing this task? My thoughts were to create a list with all employees listing a and b schedules than creating a seperate calendar with a look up to the employee list and connecting perhaps through a workflow.?

Hiding fields in EditForm

I have made a list, made a copy of the NewForm and customized it by adding and removing certain fields to what I want.

I want a different subset of fields displayed in the EditForm, however when I open editForm to customize it in SP Designer, it appears more like DispForm, than editForm and when attempting to edit an item in the list I'm first shown displayForm and then after clicking edit Item I'm shown the default NewForm without any of my changes.

How can I change which fields are visible for editing/updating an item?

My questions is similar to this one, but I do not understand the answer. Hide some fields from EditForm

Customize the display of the item picker - SharePoint 2010

I have an external content type feeding my external list and in it I have a picker as pictured.

enter image description here

The numbers don't mean much by themselves. Is there a way I can customize this to show the number and the name?

Metadata Service not showing up in Term Store Management Tool

The Managed Metadata Service appears to be set up properly and has several Groups and Term Sets defined via Central Admin, but when I navigate to the Term Store Management Tool within a site, I see nothing. I'm logged in with the same account that I configured the service with in CA; it's set up as a Farm Admin, Site Collection Admin, and Managed Metadata Service Admin. Any suggestions on what might cause this?

enter image description here

How do I add a scrollbar to a dialog?

I have created a sharepoint dialog using the HostWebDialog="true" option in my custom action. The issue is that if the data in the dialog box is larger than can be displayed there, I cannot scroll to this data without highlighting text and then dragging my mouse down.

I was able to add a scrollbar to my page that is displayed in the dialog itself, but this scrollbar is maxed out and acts as if there is no where to scroll. The scroll bar doesnt seem to be on the dialog itself.

Is there a way to force a scroll bar onto the dialog directly, and not in the body of my page I am displaying in the dialog?

mercredi 25 mars 2015

ListView Web Part Associated with List

Programmatically - How do I get to the listview web page associated with a list or library. I want to customize it and add it to a web page page in SharePoint 2013. I don't see it in the web part gallery.

Column Validation for day Monday OR Friday

I'm working with a date and time column and need a validation that returns true if the day of the week is Monday OR Friday. Users are not permitted to add an item on any other day of the week.

=TEXT([Date & Time],"dddd")="Monday"

This formula works perfectly for allowing only dates that are a Monday, I just need to add Friday into the same validator.

Sharepoint 2010

Any suggestions are greatly appreciated.

Pasting excel rich text column into Sharepoint 2013 list edit view

I was trying to paste an excel table to SP2013 datasheet view with one of the column is enhanced rich text editor. But the view stripped out the styling from excel table.

Excel table: Excel table

This is the result of the pasted text: SP List view

Any thoughts on this guys?


SharePoint 2010 FSSHTTP issue

Recently I have been experiencing issues opening documents in edit mode instead they default to open in Read-Only mode, which I believe FFSHTTP protocol is causing the issue since I was able to open the documents by applying the registry FSSHTTPoff to Office see entry below:



Usually it takes a iisreset to get everything working again without applying the FSSHTTPoff registry fix but this not permanent solution. Any suggestions why this issue is occurring or ways to resolve this?

How to edit email notification workflow in InfoPath?

Is it possible to view or edit a workflow for email notifications only in InfoPath, and NOT with SharePoint Designer?

I have been asked to manage a SharePoint site that someone else built. It uses Forms built in InfoPath. I can open a list associated with email notifications in InfoPath, but I cannot view any part of the site (including this list) in SharePoint designer. I get the following error:

Web Site Editing is Disabled. This site has been configured to disallow editing with SharePoint Designer. Contact Your administrator.

I now am the administrator with admin access, and the person who built the site is gone. It is a SharePoint 2010 site. I've learned that our company does not allow production sites to be edited in Designer.

So how do I access the workflows to modify them?? Can it be done in just InfoPath??

Synchronize with calendar from Outlook

I want to be able to view my calendar from Microsoft Outlook in SharePoint (Office 365). Of course, it should synchronize, so that all updates from made in Outlook are shown in SharePoint.

When I click in SharePoint on "Calendars -> Connect to Outlook", I can see my calendar from SharePoint in Outlook. However, I want it the other way round: Outlook -> SharePoint.

Fixed size of image in list

I have a list with a column of type url/image, formatted as image. When I put a link to a large image, it shows the image in full size.

Is it possible to restrain the size, to a fixed size, say 200x200px?

Permissions on Document App within Document Center

I'm in the process of setting up a SharePoint 2013 test environment for work. We've got a structure as follows. Names have been made generic

http://sharepoint/ - which goes to a top level, group directory which lists each company. http://sharepoint/sites/Company1 - which goes to company1's SharePoint page. This is a new site collection, part of the same Web Application but NOT a subsite of http://sharepoint/ http://sharepoint/sites/company1/documentcenter/ - This is the document center part of the company's sharepoint, which IS a subsite of company1 sharepoint.

Within the http://sharepoint/sites/company1/documentcenter there is a Web App, of the Documents app which is on the home page, so users can view the items in there and if they want to go into folders, they'll click the link of the Web App, which is http://sharepoint/sites/company1/documentcenter/documents

Hope that makes sense so far!

Permissions time. I've turned off inheritance of permissions for the DocumentCenter subsite from the main company1 subsite as we want some users to access document center but not all. On the DocumentCenter subsite I've created a permission level called Company Document Center Viewers, which has the following rights:

  • View Items

  • Open Items

  • Create Alerts

  • Browse Directories

  • View Pages

  • Browse User Information

  • Use Remote Interfaces (required for when we use Office Web Apps)

  • Use Client Integration Features

  • Open

  • Edit Personal User Information

I've then created a group called Company Document Center Viewers and assigned it that permission level. Within AD, I've created a security group called Company Document Center Viewers and added a user to that AD security group.

When browsing as the user, I can browse to http://sharepoint/sites/company1/documentcenter I can't browse to http://sharepoint/sites/company1 - this is intentional

However, when in the Document Center subsite and I try to open the Documents Web App (url of http://sharepoint/sites/company1/documentcenter/documents/forms/allitems.aspx) I get an error message saying this list hasn't been shared with me.

Back logged in as admin, I check and the list inherits permissions from the Document Center subsite.

My question is why isn't it working and letting my test user view the list so they can then navigate folders easier?

Hope it all makes sense!

Thanks guys. This site has been a huge help with getting me into SharePoint.

Can I display Google Analytic results form an external site on SharePoint?

We have Google Analytics setup to monitor our external customer site. We would like to give visibility to our employees of the customer site traffic. Is it possible to display this information via SharePoint 2013?

How can I combine data from 5 separate columns in a form library into a single column on a separate list

I have a form library that has 5 columns per entry for possible sites, I've been asked to come up with a view that summarizes all possible sites in one place. So Site A may be in Site1 column for form1 and Site3 column for form 3. I was exploring pushing the data I need, these 5 fields plus form name to a separate list to see if that would work.

Instead of current data being: Form name Site1 Site2 Site3 Site4 Site5

I would want a two column list Site Form name

Where all data in columns Site1-Site5 becomes an individual row in the new list with form name appended.

In the end we are looking for something that can present like a grouped view for a summary, i.e. At a glance Site A was mentioned 5 times, expand to see forms it appears.

Working with InfoPath 2010 and SharePoint 2010. Thanks

SharePoint Super Global Navigation bar link broken

There seems to be no documentation on the Super Global navigation menu, the Blue bar at the absolute top of the page where your login information is displayed. Can't find the name of this bar either.

This is a brand new installation, where nothing has been altered. I can Click on Newsfeed, and I am taken to the default "my" site collection that is created as a standard. "OneDrive" and "Sites" are broken, they just route to /my/ and report "We're sorry. Something went wrong with your My Site setup.Please try again later or contact your help desk."

Shouldn't Sites take you back to the top level site?

How do I edit this "Super global navigation bar?"

Get a webpart in the webpart gallery

I am trying to get a webpart from the gallary to add to a webpart page. It fails on the GetFile line saying that it can't find the file but the file is in the gallary. Is the code/path correct?

SPFile myWebPart = newSite.RootWeb.GetFile(newSite.RootWeb.Url + "/_catalogs/wp/UserQuestionnaireSummaryWebPart.webpart");
XmlTextReader read = new XmlTextReader(myWebPart.OpenBinaryStream());
var wp = manager.ImportWebPart(read, out errMsg);
manager.AddWebPart(wp, null, 1);

Include Rich text web part in document template

I have a workflow which creates a word document in document library, when a new item is created in list. The list has a rich text field. The document is created successfully with all the contents but the rich text field displays text within HTML tags. Is there a way to include rich text content in word documents?

The document is created with the help of this blog:

Any help is appreciated.

Send a customized email to users in a list

I've created a workflow that will send out an email to individuals with site access anytime a document is added to a document library. This workflow is replicated across several sites and the intended recipients of the email change with each site. The workflow allows some degree of customization of the email, which is why I created a workflow instead of using alerts. However, there is one thing I haven't been able to figure out. I would like the body of the email to read something like this:

Dear [individual],

A new document has been added to your SharePoint site [site]. Please follow this link [link] to access it.

You received this email because you are listed as the contact for [department]. If you are no longer the contact for [department], please email ***********@***.com with the updated contact information.

-end email-

Where everything within [ ] is unique to the individual receiving the email. In other words, I want to iterate over individuals in a list and send out an email unique to them. I feel like there should be a way to accomplish this, but after quite a few hours of research I've come up empty handed. Any help would be greatly appreciated. Thank you.

How do you deal with content type ids changing using a site template

I have a site where some of my custom newforms test to see which content type has been selected so that an appropriate lookup column is displayed. The new form tests for a specific content id and works fine in my site. However when I created a site template from this site the newforms don't work because the content type ID changed with the new site created from the template.

Is there a way around this?

2013 Authentication Problems

I just ran into some weird authentication issues. Apparently this has happened before a couple weeks back while I was out of the country, but here it is again.

Users on a windows operating system could not authenticate. The UN/PW prompt would come up and they would enter their AD credentials and click ok, but would be met immediately with another password prompt.

Users on OSX had no problem. Business as usual.

Users accessing via Android (only OS tested) had no problem. Business as usual.

We ended up restarting the farm and everything appears to be back up and running as per usual, but I'm perplexed. Has anyone experienced this before?

Why is Contribute Being Required At the Site Level?

We are running SharePoint 2013. I'm running into the oddest issue. On other SharePoint setups I was able to give everyone read access at the site level and then different groups contribute access to various lists. For some reason with this site, contribute permissions on a library will not work unless the person has contribute permission on the parent site.

Has anyone ran into this? The little bit I've been able to gather is that it has to do with content types. I'm not using any custom content types, just the default for the library. I'm stumped as this should be basic functionality.

Deploy Provider Hosted App out of Azure

I need to change hosting of provider hosted app from azure to my own server, Any body have any idea how to do it?

Display data of InfoPath form in a page

I have a SharePoint 2010 list which is customized from InfoPath designer and published back to SharePoint list.I have columns Name , LoginName, Address and Email. when a user fills the data in the form and saved in the list. I want to show the data in the home pag eof my site as form whenever a user is logged in and he should see the data belongs to him from the form. Is it possible I tried Infopath form webpart but cannot acheive it .are there nay other options to do so.

Webpart dropdown menu appearing elsewhere

error in webpart dropdown

As shown in the picture the dropdown menu is appearing elsewhere instead of appearing below the drop down arrow.This happens only when using in IE.. IE 8-11 all have this same issue. How can i solve this and make it appear normally.

EDIT:The site works fine in IE in the local system and doesn't show this issue , It happens only in the development server .

How do I add a scrollbar to a dialog?

I have created a sharepoint dialog using the HostWebDialog="true" option in my custom action. The issue is that if the data in the dialog box is larger than can be displayed there, I cannot scroll to this data without highlighting text and then dragging my mouse down.

I was able to add a scrollbar to my page that is displayed in the dialog itself, but this scrollbar is maxed out and acts as if there is no where to scroll. The scroll bar doesnt seem to be on the dialog itself.

Is there a way to force a scroll bar onto the dialog directly, and not in the body of my page I am displaying in the dialog?

How to rename an SPFolder

In an event receiver, in itemcreated and not creating, i need to rename the spfolder created. I've tried with meta Name or FileLeafRef but no one works

properties.item["Name"] = "new name";

Ho to achieve this

SharePoint dropdown menu in list hide value

I have a list in SharePoint which has field status. Status has 3 options. I want that when normal user add item he should be able to see only 1 value in dropdown like pending. But user added in admin group (SharePoint group) can see all 3 values. Can someone help to acheive this?

Sharepoint Meeting Workspace Problem!

i have a new site for meetings and i use it with my team and we linked to outlook ..... we mainly use it to assign and track tasks . the problem is i got a lot of requests from users they need to know the following :

  • how we can collect all assigned tasks in different meetings to me in one page ?

i'm using sharepoint Std 2010

Thanks M Farag

Use of properties.InvalidateListItem()

I am not getting relevant resources which would explain the use of properties.InvalidateListItem(). Even MSDN has no definition for it.

Can someone throw light on it

Office 2013 OneDrive Location

When a user creates a document in Word/Excel 2013 is there a way to change the location of the OneDrive option to my On-Prem SharePoint site?

Additionally, is there a way to add my SharePoint 2013 site in the "Add a Place" list?

Sharepoint 2013 server local to domain

I installed Sp 2013 farm into a local machine e now I Installed Active Directory with domains controller. SP Central admin doesn't work now. Should I re install everything or is they any workaround?

disadvantages of starting a remote powershell session and doing deployment

Are are any disadvantages of starting a New-PSSession from dev machine and deploying the wsp to QA machine remotely rather than going to QA machine and deploying the wsp??

check if required fields are filled or not in splist programmatically

I want to check if required field in SharePoint list is filled with data or not? Which method or property should i use?

Manipulating SharePoint UI over an IFrame to add missing clientside Features

I stumbled across a requirement where I had to change the RequestAccessMail via clientside code. This property is not available via CSOM or JSOM. Feature Request

There are several people who asked if this is possible and i havent found an answer that didnt say "no".

Well there is an option. When you are willing to go a quite hacky way, you can do pretty much anything that is possible via the UI when simply emulating UI interaction via JS.

Here's my example for the RequestAccessMail:

//quite dirty hack but at this point the only possibility to set the AccessRequest mail via clientside
function setAccessRequest(mail) {
var iframe = document.createElement('iframe');
//set the setrqacc.aspx link
var setrqaccUrl = _spPageContextInfo.webAbsoluteUrl + '/_layouts/15/setrqacc.aspx?type=web';
//create setrqacc.aspx hidden iframe
iframe.setAttribute('src', setrqaccUrl);
iframe.setAttribute('style', 'display:none');
iframe.onload = function () {
//this will fire 2 times - the first time when its initially loaded. the second after the changes were applied (page is reloaded (postback) after the submitbutton is triggered)
var $iframeInput = $('input[id*="_txtEmail"]', $(iframe).contents());
if ($iframeInput.length) {
//initial load - apply settings
//gets iframeInput's parent so the current input can be placed inside
var $iframeBtn = $('input[id*="_btnSubmit"]', $(iframe).contents());
//trigger the post
} else {
//second load - do callback

(Of course the code is wrapped in some warnings to prevent prematurely abortion of the running code)

This is due to the multiple asynch pageloads quite slow, but works fine.

Now here's my question - and yes I know there is no clear answer - Why not doing this for every missing feature in CSOM and JSOM (and every wanted feature that is possible via the UI)?

HELP : Question about developpement enviroment Apps Sharepoint sur Office 365

Can anybody tell me the reasons of having a public IP in the Virtual Machine that will host all the Apps that will developped and integrated in Sharepoint Online.

If also there is some official links that talks about this

Thank you very Mutch

Do Task Approval Process owners have any added privileges?

An employee has been able to approve his managers tasks for a particular site. There's now a new site and he wants to be able to do the same thing. I can't find anything in the workflows or on the old site that would allow him to do this, other than him being in the permissions group that is listed as the Approval Process owner (shown below).

enter image description here

Does the owner/owners of an approval process have any special privileges when it comes to task approvals?

SharePoint Workflow Paralell Approval task

I want to launch an approval task to different users. If one of the response of one of them is "rejected" the workflow should go to one stage and if all of them approve go to another.

I cannot use a start process because as it says "in the event of a tie the first response will be the one returned".

I've considered using a paralell block, but none of the examples I've seen seems to fit in what I want to do.

Anyone has faced this or a similar situation?

Excel Connect to SharePoint Online Document Library

We have a number of people in the field who fill out fairly complex evaluation forms in excel. These forms are submitted to a document library in SharePoint Online

What I need to be able to do is report off these submitted excel files reading and consolidating specific data (they are all of a consistent format). There may be any number of excel sheets in the source document library

Previously I would have done this using VBA but I cannot find a way of connecting to a sharepoint online document library from excel vba - I am open to other options

Creating a list-backed SQL Server database without using External Content Types

I'm trying to develop a list backed by a SQL Server database running on AWS in Sharepoint 2010 (also running on AWS), but I'm running into issues regarding authentication to the database. The only way I've found out how to create a list backed by a database is to use External Content Types, but when connecting to a data source, I have to use one of the three authentication methods:

  1. Windows credentials

  2. Impersonated Windows credentials

  3. Pass through credentials

#1 is not supported on AWS for RDS, and #2 and #3 require access to the Central Admin tool in order to create a Secure Application Store ID, which I do not have because it's managed by the corporate IT team (assume right now that I won't be able to have them add a key, although I'm still investigating this possibility).

I can create a database connection by adding a new data source, but this doesn't show up when I browse for data sources when creating an External Content Type. This DB connection allows me to use standard SQL Server authentication by specifying the username + password. Is there any way I can use this DB connection to create a DB backed list?

Apps: vs ms.sp.ext

During the set-up of a DR farm, we're facing a weird issue with apps. We have both a provider hosted app as well as a sharepoint hosted app deployed to a site using powershell. The apps are also registered using powershell. In the primary farm, all is well and the apps work ok.

Now because the content db's are synced, the apps move to the DR farm automatically. When you now click the app, SharePoint will throw an error like:

app "i:0i.t|ms.sp.ext|930fc405-2029-4afc-bfe4-8cd7a9f22e15@56775c06-47b3-4957-9b5b-003e2b4b0d23" does not exist.

Which is because the app isn't registered on the DR farm yet. So when we register the app, it starts working. This worked fine for the provider hosted app, but it didn't for the SharePoint hosted one.

When we run the powershell script to register an app, it will register

app "i:0i.t|ms.sp.ext|930fc405-2029-4afc-bfe4-8cd7a9f22e15@56775c06-47b3-4957-9b5b-003e2b4b0d23" does not exist.

But when opening the SharePoint hosted app in the brower, the error will read:

app "i:0i.t||930fc405-2029-4afc-bfe4-8cd7a9f22e15@56775c06-47b3-4957-9b5b-003e2b4b0d23" does not exist.

Note that the first reads ext and the second reads int, so they do not match (error is valid from that perspective). I suspect that int = sharepoint hosted and ext = provider hosted, but I haven't found any details on that. The powershell cmdlets only let me register "ext" principals, as there is no way to specify "int" instead. The weird thing is that this does work ok on the primary farm, so aparently the normal installation procedure registers the correct type.

Anyone ever seen this behaviour and perhaps has more indepth knowledge on what's going on behind the scenes?

Does adding a web part to a page make a copy of the web part definition?

The setup: - Custom Summary Link web part - Custom SummaryLinkMain.xsl - Custom ItemStyle.xsl - JavaScript file that the SummaryLinkMain calls from a separate site collection (an internal CDN) and uses in the ItemStyle.

From what I've seen, it seems like adding a web part to a page makes a copy of that web part on the page, including its *.webpart definition. This is causing issues because we have a bug where we have to change a custom Summary Link web part definition (.webpart) to point to a new SummaryLinkMain.xsl stylesheet so it can load the above JS file properly.

However, just updating our custom .webpart file DOESN'T seem to update the EXISTING custom web parts we've already put onto our pages. It looks like we'd have to go through dozens of pages and reinsert the web parts in order for them to get the updated web part definition.

(A): Does SharePoint make a copy, or is it possible for a change to the web part definition to filter down to all existing web parts that were spawned from that definition?

(B): If A doesn't happen, is there a way to force refresh of all the web parts somehow? Obviously we're trying to avoid a lot of work in rebuilding them all.


What is the difference between a sharepoint site page and web page

What is the difference between a sharepoint site page and web page. In site contents I have the ability to create the page under site page or web page? Im looking for a good explanation between the too.

excel file uplodaded in sharepoint 2013 document library not opening

I have a document library in sharepoint where excel files are uploaded. But when we click on the excel file we are not able to view it.

It give me the following error. Microsoft Office Excel cannot access the file. There are several reasons: The file name or path does not exist. The file is being used by another program.

And for some browsers it just asks for username and password and after entering the userid and password,it doesnot get opened.

Am I missing something?Please help.

Using SharePoint 2013 Online, how do I run getSubwebsFilteredForCurrentUser on sibling site collections and display in a single page?

The page containing the results belongs to one of the sibling sites and I would like to be able to loop through the site collections dynamically without providing a list of collections first.

How to encapsulate code in SharePoint 2010 and make it accessible across multiple solutions

Anyone know the best way to reference functions in a solution to be used for any/all other solutions (web parts, application pages, timer jobs, etc)?

I have several small modules of code that I've copied to multiple solutions that I'd prefer to maintain in one solution that can be called from other solutions.

I don't know the best way to do this.

Please provide step-by-step instructions or a link that has that.


What I've discovered so far...

Option 1: I found instructions on how to Creating a Custom ASP.NET (ASMX) Web Service in SharePoint 2010, but I've been told that's not the most efficient way to reference functions in another solution and that there's a performance hit for that.

Option 2: I also found instructions on Working with Assemblies in the GAC, but I don't know if that's the most efficient way to do this either.

I know Option 1 works. I've tried it. I like this option because I ONLY have to redeploy the web service after making updates to it, not the calling solutions. I just don't think it's the most efficient method.

Start survey on file creation

Is it possible to initiate a survey whenever a new document is created in a specified library? I was thinking to create a workflow, but i'm not sure how.

Thanks in advance!

How to add more than 2 levels to structured navigation?

I need to implement structured navigation in order to have Audience Targeting capabilities. it appears that structured navigation only supports 2 levels. is that correct? is there a way to override without programming?

I am trying to achieve the following for left hand navigation. This navigation will be for a bi subsite of host name site collection.

Menu Item 1

  • Sub Item 11

    • Sub Item 111

sharepoint enterprise 2013 sp1 farm

SharePoint 2010 REST Date/Time format

In SharePoint 2010 REST API when I call to _vti_bin/ and get JSON response the date/time is returned as /Date(1421146908000)/ (I found some information about it but not still sure what this number counts and from which epoch). But when I get actual value calling to _vti_bin/, I get Edm.DateTime value 2015-01-13T11:01:48.

Does anyone know

  1. Is it always the case I can rely on? The reason is that I use actually _vti_bin/ListData.svc/ service of SP 2013 server (since I don't have SP 2010).

  2. Is there some official information about date/time formats returned in different cases?

  3. Is it really Edm.DateTime or may be Edm.DateTimeOffset?

Thanks a lot!

Configuring Sharepoint Content Sources

I have two web applications. I set up both to be crawled (Search Service Application: Edit Content Source>Start addresses, Crawl everything under the hostname for each start address).

If I understand correctly, those two paths would be considered under "local Sharepoint results" in the list of result sources. However, when I search from the search center, only results from the first web application are seen. Nothing is visible from the second web application.

What are possible things to check to include site collections on that second web application in my result sources?

It seems I have the opposite problem from this OP. I want to restrict results, but they have to be included before I restrict them.

EDIT: In my search service application, I've created a result source called Build Eagle. The query text is {?{searchTerms} -ContentClass=urn:content-class:SPSPeople} Path: When I test query, I get 72 results. (Logged into central administration as me). I have a search site set up at My search center is When I go to, and edit the search results webpart, I set the result source to the Build Eagle (service), and my query text is simply {SearchBoxQuery}. I then go to test>show more, and enter various {SearchBoxQuery}. No results show up. Could it have something to do with the fact that the search is in a different site collection?

Silverlight Application in a .ascx page

Produced a silverlight application which i wish to put in an ascx page such that once produced the control, i can added dynamically to forms when need be.

I have searched a lot the web but couldn't find a process by which i would be able to accomplish this. I managed to create a web part which contains the silver-light application, yet a webpart doesn't meet the requirements of my problem. can anybody suggest a resource which would help me accomplish what i need to do?

Use a web part list item as element class

I'm trying to use the line of code below to dynamically insert a class in an element but it prints it as a code instead. Any Ideas on how I can achieve this.

list column name


Element Code

<div class="alert-box {{%-Class-%}}">

Check in/Check Out Interaction with Workflows causing issues (SP2010)

The Check in/out on a library is causing issues with our workflow. If I create a simple workflow on library, it works correctly until I apply check in/out. With the Check in/out turned on my workflow looks like this:

If current Item:Checked Out to is empty

and Current Item: Name is not empty

Check out item in Current Item

then Set Title to Current Item:Name

then Check in item in Current Item with comment: Title Updated

then Stop the workflow and log Complete

When I upload a document to the library the status remains 'Waiting to start', but never completes. When I create a new document from a content type the workflow runs correctly, but remains checked out for a long while after I've initially checked it in.

I can't get my head around why the workflow won't work correctly with Check in /out turned on.

Unable to convert as UDCX file in sharepoint 2013 infopath form

I try to convert my connection library to .udcx file. but i throw following error. enter image description here

I try below method

  1. Add Desktop Experience feature on Windows Server 2012 (its already enabled)

but no use....

SharePoint Conditional Formatting without using Designer

I am trying to apply conditional formatting to my SharePoint list based on a few conditions.

For example I have a column (Month Needed) that the user selects a date from a drop down list in the format 11/2015 and so on. I would like to highlight (with colors) any row that has a date that is 90 days or less from the current date?

Unfortunately my SharePoint site does not allow me to create web parts in Designer so I am unable to add conditions that way and the javascript examples I have found don't really do what I need it to.

Here is an example of what I found:

so a statement like the following:

if(text in Month Needed Column is 90 days less than Current date) { background color = 'red'; }

Any guidance on how to accomplish this would be extremely helpful.

Use a HTML form to create new list items

I've created a HTML form webpart with some inputs. I want to insert the data contained by the inputs into a Sharepoint List on submit.

How can I do that?

Keyword query returning results from non shared site also

I am using KeywordQuery (KQ) to get items from SharePoint. My site structure is as follow:



User Bob has access to all the site (Read) while Alice only has access to site1.

As expected, for Bob the KQ returns results from all site, but for Alice it also returns items of SiteA even she doesn't have access to it.

Could you please specify which parameters am I missing while creating the KQ object.

My KQ object has following properties: Querytext, RowLimit and Select Properties.


Client Context that I am passing to KQ

SharePointContextToken contextToken = TokenHelper.ReadAndValidateContextToken(token, request.Url.Authority);
string accessToken = TokenHelper.GetAccessToken(contextToken, targetWeb.Authority).AccessToken;
clientContext = TokenHelper.GetClientContextWithAccessToken(targetWeb.ToString(), accessToken);

SharePoint 2013 Search and parser errors

One subsite in my SP environment, with xml-files stored. The crawl throws this error, 30k times,

Processing this item failed because of a xml parser error

I tried to do the steps from this guide, , but it did not work for me.

I also have a small amount of word parser error and pdf parser errors.

Here is the whole error:

Processing this item faild because of a XML error. (Error parsing document 'http://mySPSite/mySubsite/myList/theNameOfTheXMLFile.xml'. Invalid XML stream - line (6), position (19). ;; SearchID = number of the search id)

They all has the "line (6)" and the "position (19)".

What is the reason for those errors?

This is my crawllog, it recrawls even if it is incremental and full seems to have sucesfully ended. enter image description here

Search items through search service or custom application

I have an application which is written in some language. Now, my customer developed some service using Java based webservices. The question is whether we need to crawl json based webservice and using search service application to bring the result into sharepoint like OOTB / develop an apps and through client side, connect webservice and bring result into custom page. Which is more efficient?

CAML Query for getting folder contents based on folder parameters

I have the following folder structure.

Folder1 attr1="cat1"
>> file1 attr2="subcat1"
>> file2 attr2="subcat2"
Folder2 attr1="cat2"
>> file3 attr2="subcat1"
>> file4 attr2="subcat2"
Folder3 attr1="cat1"
>> file5 attr2="subcat1"
>> file6 attr2="subcat2"

I want to get all files(only) which is under folder having field attr1 = cat1, i.e., file1, file2, file5, and file6. Note that attr1 is not available for files. A possible solution is to get all folders, then in a loop, query for files using FolderServerRelativeUrl. But I don't think it is optimal because there will be too much delay for the retrieving the final list, as each ExecuteQuery will take some time. I am using Client Object Model for querying. The CAML query I use only retrieves Folders at Present.

string caml = @"<View Scope='RecursiveAll'>
<FieldRef Name='attr1' />
<Value Type='Text'>cat1</Value>

Missing document history move file to record center SharePoint 2013

I have a document library with some documents set. I created a site collection with record center as template. I configured everything so when I press "Move to other location" and click on the Location created by my administrator, the document set with all the files are transfered to the records center without any problem. The only problem is that all my documents lose their history in the records center. Why? And how to keep it?


PowerShell for removing service application association

I have created a Managed metadata service application named MMD1.

It's associated with 2 web applications, say webapp1, webapp2. Now I am creating a new MMD called MMD2. I would like to remove the MMD1 association with webapp1 and webapp2 and associate it with MMD2.

I am trying to do this with PowerShell. But I do not know what API to use. Help is appreciated.

$serviceapplicationname = "MMD1"
$spapp = Get-SPServiceApplication -Name $serviceapplicationname
$spguid = $
$webapp1 = Get-SPWebApplication http://webapp1

Disable Suggestions when Adding New Items for a List

When you add a new item in a list, a dialog box is displayed together with its columns. When I try to enter a value for a certain column, a dropdown list is shown and all other inputted values for that column are being displayed in the dropdown list.

How can I disable this Suggestion feature for my columns when adding a new Item in the List?

Can it be done via SharePoint Designer or in the actual SharePoint list page?

Microsoft products 2010 installation

I wants to deploy a custom solution for our team portal.

But I don't find any Microsoft products list in my system how to install it?

Bind SQL data with SharePoint Gridview

I have a question that, I'm developing a sharepoint solution, In Application Page, I want to place SPGridView and I have to bind it with sql server data. Is it possible and if yes, how?

mardi 24 mars 2015

Users from trusted domain can't access SharePoint farm

I have been given the task to give users from 2 new trusted domains (B & C) access to one of our SharePoint farms.

Currently, these users reside in 2 seperate, but trusted domains.

The "native" users from Domain A are synced by a User Profile Service Application. After adding a new sync connection to the forest of B the crawl runs, but adds 0 new user profiles. I guess the user profile sync account doesn't have the appropriate permissons on B to do the sync.

What I am able to do, is add B\domain users and C\domain users to the visitors group of a Site Collection. However, this doesnt grant them access and results in an Access denied every time.

Besides forwarding this MSDN article to our Exchange admins, which steps can I do, to grant those users access (possibly without user profile sync?)

Effects of moving Managed Metadata terms withing term set

We currently have a SharePoint 2013 Managed Metadata hierarchy similar to below:

Term Set 'Departments'
---'All Departments'

and would like this to look more like:

Term Set 'Departments'
---'All Departments'
--- ---'HR'
--- ---'Sales'

that is, with HR and Sales 'underneath' All Departments, and leave Purchasing on it's own.

What are the repercussions in moving the terms around in regard to managed metadata based search filtering, or general list based filtering (i suppose even managed navigation). Does anything break?

My goal is to have search/list filtering for 'All Departments' bring up everything in and under that term, instead of tagging an item as both 'All Departments' AS WELL AS 'Sales'.

Thank you in advance.

Is there any clean source code for Microsoft.SharePoint.dll 2013 on the internet?

for learning purposes, I want to debug code inside Microsoft.SharePoint.dll, I reflect the code and save it as project (using reflector) but when I try to build this project I find a lot of bugs, Is there any clean source code for Microsoft.SharePoint.dll 2013 on the internet?

How to know what kind of permission (Full, manage, write) is used for the current App?

I planing to build an JavaScript library to manipulate SharePoint Lists and Items , which developer can use with there SharePoint Hosted apps, and I want to publish on CodePlex,

anyway, this JS library can access the items using two ways, and both of them are working fine, but one of them have better performance.

form my library I need to know what kind of permission (Full, manage, write) is used for the current App, and based on that I can run the fit code.

Update: My App authorization policy is default (App-only policy)

How do I change thumbnail titles in O365 SharePoint asset lib"

I have an Asset Lib in SharePoint online with thousands of flower images. Currently the thumbnail shows the title of the photo, the type, and the dimensions. I need to change these titles pull from other image metadata fields instead.

I looked at this great post but I cannot seem to retrofit it to SharePoint online.How to edit xslt for thumbnail view of Asset Library.?

(I am happy to pay for a solution).

enter image description here

Power to the User! (no, really)

I am a non-admin user of a SharePoint site that was designed for the upload of files and websites, then a search by criteria/tags that we attached to it.

I would like to have new and better ways of searching or mapping these resources. Here is my first idea. I appreciate anyone's ideas for helping.

  • Create a URL list whereby I could see all of the results from a normal search, but in URL format, like a sitemap for the resources on the site. Please excuse my syntax in this example of one of the searches:"interesting"&genre="fiction"&length="short"

SharePoint 2013 Content By Search Disable ASCII Sorting

I am building a Content By Search web part that read data from a custom list with one column "Title". I have updated the search schema to mark the title column as sortable and now I can choose the title to sort by however the search results is always sorted by ASCII like [0-9A-Za-z] so if I have the following items

  • Hossam

  • A

  • a

The search results will be

  • A

  • Hossam

  • a

So I need your support on what I can do to make my search results like below

  • A

  • a

  • Hossam

I have found the following link that is talking about the same issue with SharePoint 2010 FAST search but no hints about how to fix it on SharePoint 2013

Hide SharePoint List Item based on Condition using Views

I have list holding customer name and expiry date list items .And I need to create a view which should hide all the customers whose expiration date is passed

Example : If Customer A is holding expiry date at 2015-(05) MAY 25 then this view should not display customer A in the list

Can any one help me how can I done this using views

Render Image from REST API Call

Here's the var from the function:

var aoTiles = "<div class='col-md-4 tile'><div class='tileImg' style='background: url(" + [value=this.Image_x0020_Thumbnail_.Url] + ") no-repeat 0 0;'><span class='openRotator'></span></div><div class='tileTitle'>" + this.Title + "</div><div class='tilePrice'>" + this.Product_x0020_Price.toFixed(2) + "</div></div>";

Instead of rendering the image, I get nothing.

If I do something simple like this:

var aoTiles = "<div class='col-md-4 tile'><div class='tileImg'>" + this.Image_x0020_Thumbnail_.Url + "</div><div class='tileTitle'>" + this.Title + "</div><div class='tilePrice'>" + this.Product_x0020_Price.toFixed(2) + "</div></div>";

If you need the full function:

function addOnsTiles(){
async: false,
url: "/_api/lists/getByTitle('Products')/items",
type: "GET",
headers: { "Content-Type": "application/json;odata=verbose", "Accept": "application/json;odata=verbose" },
success: function (data) {
$.each(data.d.results, function () {
var aoTiles = "<div class='col-md-4 tile'><div class='tileImg'>" + this.Image_x0020_Thumbnail_.Url + "</div><div class='tileTitle'>" + this.Title + "</div><div class='tilePrice'>" + this.Product_x0020_Price.toFixed(2) + "</div></div>";
error: function (data) {

return true;

It gives me the image URL but still no image.

Why is it not rendering?

FBA SharePoint site collection failed login

I maintain a SharePoint Site with 17 site collections. It's configured for FBA as an extranet for external clients to log in and check things. It has been working for 4-5 years with no issues at all. I just recently (January 2015) changed the password on one of the accounts that is a Site Owner because I wanted to prevent some dufus in the company for logging in messing up things like he already did. So now I'm getting 4 exceptions in the Event Log every 2 hours without fail. The error in the ULS logs is: Unexpected Password check on 'AccountName' generated exception: 'System.ServiceModel.FaultException`1[Microsoft.IdentityModel.Tokens.FailedAuthenticationException]: The security token username and password could not be validated. (Fault Detail is equal to Microsoft.IdentityModel.Tokens.FailedAuthenticationException: The security token username and password could not be validated.).'.

I know the account name being used and the site collection it is trying to log into as it's all in the log. If I deliberately try and log in with the wrong password I get the exact same error.

My questions are: 1. How can I find out what IP address the attempted log in is coming from? 2. Could this be something I set up years ago and forgot what it was? i.e. is it even possible to set up an FBA account to run a service or Timer job in SharePoint. I checked the time jobs and saw nothing wring.

Thanks for reading my long winded question. Any sort of clue or help would be fantastic.

Rich text box is distorted

enter image description hereHi All

After migration from MOSS 2007 to SP 2010, In a list, Multi line Rich text box is distorted, its tool bar is showing large images, please see attachment and give a suggestion to resolve this issue.

Thanks in Advance

Get sub site title that you have access to with REST API

I followed codes sample hereenter link description here with security trim to get a list of sub site titles that user have access. I got "access denied. You do not have permission to perform or access this resource. Is there a solution for this? The users have readonly at the root site and contribute at subside.

Below is the codes: http://site/_api/web/webs/?$select=title,effectivebasepermissions&$filter=effectivebasepermissions/high%20gt%2032

Cant display Site

I am a newbie to SharePoint. Built a SQL server and another server for IIS & SharePoint. I installed everything without an issue, got to the Central admin page. Created a Web Application, then created a site Collection. I am unable to site.

I got error saying "This Site has not been shared with you" I set myself and the service account as the site admin. I really don't know what I didn't wrong. Please help. Thank you.

GetFileByServerRelativeUrl returns corrupt document

I'm trying to read a SharePoint document using GetFileByServerRelativeUrl. The code seems to work (it throws no exceptions). It's returning a byte array that should represent a Word document. (It's eventually going to be used from a CRM plugin assuming I get this working and barring plugin sandbox restrictions.) The code is below.

public byte[] GetFileContent(string site, string libraryName, string folderName, string fileName)
_spo = SpoAuthUtility.Create(new Uri(site), _username, WebUtility.HtmlEncode(_password), false);

var digest = _spo.GetRequestDigest();

var getFileUrl =
string.Format("_api/web/GetFileByServerRelativeUrl('/sites/dev/library/folder/" + fileName + "')/$value");

var url = new Uri(String.Format("{0}/{1}", _spo.SiteUrl, getFileUrl));

var webRequest = (HttpWebRequest)WebRequest.Create(url);
webRequest.Accept = "application/octet-stream";
webRequest.Headers.Add("X-RequestDigest", digest);
webRequest.Headers.Add("binaryStringResponseBody", "true");

var result = HttpHelper.SendODataJsonRequest(url, "GET", null, webRequest, _spo);
return result;


If I take the result of the function GetFileContent above when reading a Word document and do a File.WriteAllBytes with the result and try to open the file, Word says the file is corrupt. If I take the result of a text file (.txt) and do a File.WriteAllBytes, it works just fine and opens in notepad. I have set "binaryStringResponseBody" in the request header. If I read the word doc file from my hard drive using File.WriteAllBytes and write it back out, it opens fine. The word doc in SP is good - clicking on it's link opens it just fine in Word online, so that's not the issue. If I open the value of url.AbsoluteUri in my browser, it downloads a file. I rename it to have a .docx extension and it opens. It only fails when I read it from SharePoint. Any ideas?

Multiple Yammer feeds on same sharepoitn page

as part of a new intranet I am making for the company I am looking into Yammer and how it works with onsite SharePoint.

Using yammer basic I have set up a couple of groups and have run into a slight problem with trying to put them into the same page in SharePoint using js.

Problem: Using Content Editor or Script editor it simply adds the next feed underneath the previous feed. All functionality is maintained however I would like to have the ability to place feeds in different areas on a page.

At the moment I am aiming for a page to contain: yammer myfeed, sharepoint feed, yammer group feed which I intended to show management the difference between the various feeds.

Check In Document using Adobe Reader Returns Error Message

There is an error message that is being returned when a pdf document is being checked in using Adobe Reader XI.

This is being reported by some users. All users have the same permission level for the site and the document library, Approver.

All users environment: IE9, Adobe Reader XI, Windows 7.

Steps to check out / check in document:

1) Click on document on SharePoint 2010 Document Library

2) Dialog box click 'Check Out and Open'

3) Add a comment/highlight

4) Check In Document: File->SharePoint Server-> Check In

5) Add a comment to the check in dialog box 6) After clicking okay the following error message appears

Adobe Reader cannot check in the document as it has been deleted or there is a network connection problem. Please check your network connection or contact the server administrator.

Adobe Reader Check In Document Error Message

I created a new document library to test if the document check in would work on another library. And it did work on the new library, the permission levels are the same, they are inherited from the site itself. One difference I did note was that the document library with the issue does have over 5000 items, which is the list view threshold.

How can this issue be resolved?

Sending an email as "High Importance" via SPD Workflow

Is it possible to send an email as high importance through a SharePoint Designer Workflow?

Use case would be if a checkbox is checked, send email as high importance. If it is not, send regular email.

Merge SharePoint List using Nintex Workflows

I have Two lists, I need to merge those 2 lists into a single list and update every week

List-1 ID name age D.o.b Gender


ID name department Salary Location

List -3 (Combined List)

ID Name age D.o.b Gender department Salary Location

I need to achieve List-3. List-1 and List-2 are updated daily. Every week i need to update List-3

I dont have designer and Visual Studio. Only option I have is Nintex Workflows, Can any one help me how to do this?

Max number of items in a sharepoint list?

I currently have 28679 records in my sharepoint list, what is the max size with attachments a list can hold as well has max number of records in a list.

Thank you

Can I display Google Analytic results form an external site on SharePoint?

We have Google Analytics setup to monitor our external customer site. We would like to give visibility to our employees of the customer site traffic. Is it possible to display this information via SharePoint 2013?

N Level delegation reusable SharePoint designer 2010 workflow

I have a requirement to create an approval workflow, wherein users can delegate it to Nth level as per there requirement.

Please let me know if this is possible and how?


String was not recognized as a valid DateTime

I am fetching data from external list using SPListItemCollection.GetDataTable() method. But this method throws error:

"String was not recognized as a valid DateTime.Couldn't store <2015-03-24 13:51:51:007> in MyDate Column. Expected type is DateTime.

I searched in the forum i found this post

I tried it, but no luck! Any thoughts?

Where to keep configuration for SharePoint solution

Where do I store a configuration of a sharepoint solution? The solution has a feature activated on a site collection, so there will be multiple instances of it running on a farm. Installation and feature activation will be automated with powershell because the feature needs to be activated on multiple site collections. All the instances need the same set of configuration parameters, set of keys and values. Where do I store them? A file, registry or some other place? If if is a file, is it a good idea to store it in c:\ProgramData directory?

Each instance of the solution writes logs. Is it a good idea to store the log file at c:\ProgramData as well?

Redirect non existing page to Default Page

I have a Sharepoint Foundation 2013 running for nearly 2 years now and its primary URL is, all is working fine.

Then toady we migrated and merged our company intranet to this Sharepoint Instance and I added a new Alternate Access Mapping called, this also works fine it resolves to

The problem is when a user have a bookmark in their browser like or it does not do anything, how do I handle this situation, meaning how would I redirect those to just