Tuesday, August 8, 2017

The URL is invalid, it may refer to a nonexistent file or folder or refer to a valid file that is not in the current Web in SharePoint 2013

image

This is common error when you are working with SharePoint.

This is can be due to various reasons but most common erros are due to Database issues.

1. Not Enough Space

Check your database related to SharePoint including

  • SharePoing Content Database
  • SharePoint Contect Database Logs
  • Temp Database Logs
  • SharePoint Service Databases
  • SharePoint Service Databases Logs
  • SharePoint Service Databases Temp Logs

 

check these databases have enough space to perform actions.

 

2.Not sufficient permision

Other reson is for not having enough permision to SharePoint Content Datase. YOu can find the related content databases from browsing through the cetral admin.

image

Go to application management and then click on Manage content databases.

image

Then you will find the related content database for the web applicaton. So make sure those databases having db_owner permision fo SharePoint Farm Account.

Tuesday, March 7, 2017

This view cannot be displayed because it exceeds the list view threshold (5000 items) enforced by the administrator.

“This view cannot be displayed because it exceeds the list view threshold (5000 items) enforced by the administrator.

To view items, try selecting another view or creating a new view. If you do not have sufficient permissions to create views for this list, ask your administrator to modify the view so that it conforms to the list view threshold.”

image

And if you are more dig in to it, the error will be occur in your

  • Web Parts
  • Custom Scripts
  • SharePoint Apps
  • CAML Queries

Which is related to that list.

First we have a look why this is happening.

The Live View Threshold is item count which is limited by SharePoint Administrator to process by SharePoint server at a time.

Further elaborating when you are viewing or query (CAML, ODATA, and REST) against the list SharePoint will process the entire set of items to get the required results even though you have mentioned limits or filters unless it is not indexed.

Thus when it is exceeding threshold limit (5000 default) SharePoint will throw that error to you.

 

HOW TO RESOLVE

Increase the List Threshold as a Temporary Fix

The easiest way is Increase the Threshold List View Limit. But this should be temporary and it is not good for server performance.

First you can go to Central Administration and then Manage web Applications

image

Then select the web application you need to increase the List View threshold. And go to general settings and Resource Throttling.

image

Then you can change the List View Threshold to accommodate the list items limit.

image

 

Recommended Approach to use Indexed Columns

Recommended approach is used to cater this problem using indexed columns. If you use the index column SharePoint does not need to iterate entire list to deliver the results.

Let’s have a look for sample scenario. Assume that you have a list with 6000 items over 5 years’ time and your default view throws that error.

So first you need to increase the List View Threshold to perform operations as I mentioned in the temporary fix.

Then you need to create an Indexed Column.

Most common used scenario is use [Created] SharePoint default column as an Indexed column. But might be differ from your scenario.

 

Create an Index Column

Go to List settings and click on indexed columns

image

Click on the Create a new Index Link

image

Then choose a column that you need to Index and Create It as an index column.

image

Then you can edit the Filter in Default view to show only last year by adding [Today]-365 as an filter expression.

image

Then you can change the List Threshold back to 5000. But make sure you are adding [Created] column expression for your CAML queries, REST queries and other queries.

Thursday, March 2, 2017

SharePoint Web site Keep on Prompting for credentials– Full Article.

This article breaks into three sections.

  • Identify and Cause

  • Add Exception to Strict Name Checking

  • Disable Loopback

Identify and Cause

There are many reasons to happen this but most of the time it will happen when you change the Access mapping to match your domain.

For an example you might have webwfe01 as your web application in your default zone. And if you change that to www.sampleweb.com this may be occurred for Windows Users.

image

This is because by not having Fully Qualified Domain name specified is not matching with the local machine.

For an Example,

Your local machine can be in a domain myorg.com and the specified Mapping is sampleweb.com

Thus this will cause LoopBack check which it true by design for security reasons.

Microsoft specifies two methods to resolve the issue.

  1. Disable Strict Name Checking

  2. Disable Loopback Check

REF: https://support.microsoft.com/en-us/help/896861/you-receive-error-401.1-when-you-browse-a-web-site-that-uses-integrated-authentication-and-is-hosted-on-iis-5.1-or-a-later-version

You need to do it all SharePoint servers for safe side in the future service deployment. But it is necessary for all Front End servers.

Disable Strict Name Checking in IIS

This is use full in many scenarios. For me it’s more use full for disable keep on prompting credentials in SharePoint 2013 Environment.

In this method you need to add your domain as an exception list to IIS for not checking the FQDN for loopback.

Open the RegEdit.

image

And navigate to

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa

and click on MSV1_0

image

Then add new Multi Connection String

image

And add BackConnectionHostNames

Then you will see that is added to the registry.

image

You can double click and add your fully qualified domain names (One per line) that will be working as an exception.

image

Then you can save and restart the IIS.

Disable Loopback Check in IIS

This is use full in many scenarios. For me it’s more use full for disable keep on prompting credentials in SharePoint 2013 Environment.

In this method you can simply disable the check by editing the following registry key.

Open the RegEdit.

image

And navigate to

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa

image

Click on Lsa Registry and add DisableLoopbackCheck registry key as DWORD value.

image

After adding the registry key you can find the entry as follows.

image

Then double click the key and Enter 1.

image

And click OK.

Then restart the IIS.

Thursday, February 16, 2017

You are being redirected to the following url that was not registered as the app launch url

“You are being redirected to the following url that was not registered as the app launch url https://xx?SPHostUrl=xx&SPLanguage=enSPClientTag=0&SPProductNumber=xx&SPAppWebUrl=xx&{AppContextToken} If you trust this url, click here to proceed to the app now. Otherwise go back to the previous page or close this page."

It is common that you may have encountered this kind of an error when you are accessing an App that you have developed and published to the SharePoint 2013.

There can be many deep reasons behind the message such as

  • Not provisioning the app web correctly
  • Errors on App management service

But most of the time it is because of not registering your app in the SharePoint.

You can simply follow following steps to register your app in the current SharePoint site.

First go to Appreg.aspx page which used to register the app in http:// xxx/_layouts/15/Appreg.aspx. Then you will find a following interface where you can register your app with SharePoint.

image

But you need to make sure the values you are entering is matching with the AppManifest.xml in your solution.



<?xml version="1.0" encoding="utf-8" ?>
<!--Created:cb85b80c-f585-40ff-8bfc-12ff4d0e34a9-->
<App xmlns="
http://schemas.microsoft.com/sharepoint/2012/app/manifest" Name="ShopSAdmin" ProductID="{4813c773-d1b1-4ec6-8274-32f1152bd6b7}" Version="1.0.0.1" SharePointMinVersion="15.0.0.0" >

<Properties>
<Title>ShopSAdmin</Title>
<StartPage>~remoteAppUrl/Pages/default.aspx?{StandardTokens}</StartPage>
</Properties>

<AppPrincipal>
<RemoteWebApplication ClientId="*" />
</AppPrincipal>

<AppPermissionRequests>
<AppPermissionRequest Scope="
http://sharepoint/content/sitecollection" Right="Manage" />
</AppPermissionRequests>
</App>