Calculated Column in O365 SharePoint Online with Example

There is no difference in calculated column formula in SharePoint Online from earlier versions of SharePoint. Let us see an detailed example in this article.

Functional Requirement

I have a column called “Activities” that is a choice column and has the following options:

  • Bylaw Development – Working Papers
  • Compliance Monitoring – Permitted Activities

I need to have 2 calculated columns to get split the ‘Activities’ choice – one for Activity and one for Subactivity.  For ‘Activity’, I need to get everything to the left of the ” – ” and for ‘Subactivity”, I need to get everything to the right of the ” – “.

For example:  For Bylaw Development – Working Papers, the activity should be ‘Bylaw Development’ and the subactivity should be ‘Working Papers’.

Solution

Step 1 : Create two columns “Activity” and “Subactivity” as a Single line text

Step 2: Create column “Activities” as below,

Step 3: Enter the items as below,

Step 4: All item view should display as below,

Hope this article help. This article is applicable to other version of SharePoint too.

Search in SharePoint 2013 and O365 SharePoint Online Architecture and understanding

Introduction

Search in SharePoint 2013 and O365 enables users to find relevant information more quickly and easily than ever before and makes it easy for Search administrators to customize the search experience. It also provides several API sets for more advanced customizations and solutions.

Search Architecture

The search architecture contains search components and databases. How you structure the search architecture depends on where you intend to use search, i.e. for the enterprise or for Internet sites. When building the search architecture, you should take into account considerations such as high availability and fault tolerance, the volume of your content and the estimated amount of page views and queries per second.

Search Components

1

1.Crawl Component2

This component takes care of crawling the content sources such as (SharePoint sites, websites & file shares etc…) and extracts the crawled properties and metadata and sends that to the content processing component.

2. Content processing component3

This component receives the information from the crawl component and then processes and sends it to the indexing component. It also interacts with the analytics processing component and is responsible for mapping crawled properties to the managed properties.

3. Analytics Processing Component4

This component takes care of analyzing what users are querying on and how they interact with the results. This information is used to determine relevance, generate recommendations and also used for generating search reports.

4. Indexing Component

This component takes care of receiving the information from the content processing component and writes it to the search index. It also takes care of handling the queries and sends back the results to the Query processing component.

5. Query Processing Component

This component handles incoming query requests and sends them to the indexing component for results. It also takes care of query optimization.

6. Search admin Component

This component manages administrative processes as well as changes to the search topology, such as adding or removing search components and servers.
Please note that these 6 search components can be distributed across multiple servers to provide high availability as well as improve performance as shown in the image below.

5

Search databases7

1. Crawl database

Stores tracking information and historical information about crawled items such as documents and URLs. It also stores information such as the last crawl time, the last crawl ID and the type of update (add, update, delete) during the last crawl. It also provides the crawl queue for items currently being crawled.

2. Link database

Stores unprocessed information that is extracted by the content processing component and information about search clicks. The analytics processing component analyzes this information.

3. Analytics reporting database

Stores the results of usage analysis. It extracts information from the Link database when needed.

4. Search administration database

Stores search configuration data. This also hosts the Search service application configuration and handles crawl state orchestration, including the content source crawl history.

SharePoint Admin Center Settings

6

SharePoint on-premises and Online Differences

Both SharePoint on-premises and Online have search capabilities. The big difference is what their search indexes can include. Typically, when the phrase enterprise search is used, it means that the search engine in question can index multiple, disparate content sources.

In the case of SharePoint on-premises, this is true. SharePoint has long been capable of indexing SharePoint content, as well as content stored on file shares, Exchange, websites and Lotus Notes databases, among various content sources. Starting in 2007, Microsoft added the capability of indexing structured data from databases and other applications through the then-called Business Data Catalog. That feature has since matured and is now called Business Connectivity Services (BCS), and it allows virtually the same capabilities.

The same is not true of SharePoint Online. The search engine can index all content stored in SharePoint and sources connected through BCS, but not index file shares, other websites or Lotus Notes databases. While the capability is largely constrained based on where SharePoint Online is hosted, the more fundamental difference is the controls available to administrators, the ability to define other content sources, like on-premises implementations, simply does not exist.

Search Features – O365 Comparison plans

Search features

Office 365 Enterprise E1

Office 365 Government E1

Office 365 Enterprise E3

Office 365 Government E3

Office 365 Enterprise E4

Office 365 Government E4

Office 365 Enterprise E5

Advanced Content Processing

Yes

Yes

Yes

Yes

Continuous crawls

Yes

Yes

Yes

Yes

Custom entity extraction

No

No

No

No

Deep links

Yes

Yes

Yes

Yes

Event-based relevancy

Yes

Yes

Yes

Yes

Expertise Search

Yes

Yes

Yes

Yes

Extensible content processing

No

No

No

No

Graphical refiners

Yes

Yes

Yes

Yes

Hybrid search

Yes

Yes

Yes

Yes

Manage search schema

Yes

Yes

Yes

Yes

On-premises search index

No

No

No

No

Phonetic name matching

Yes

Yes

Yes

Yes

Query rules—Add promoted results

Yes

Yes

Yes

Yes

Query rules—advanced actions

No

Yes

Yes

Yes

Query spelling correction

Yes

Yes

Yes

Yes

Query suggestions

Yes

Yes

Yes

Yes

Query throttling

Yes

Yes

Yes

Yes

Quick preview

Yes

Yes

Yes

Yes

Ranking models

Yes5

Yes5

Yes5

Yes5

Refiners

Yes

Yes

Yes

Yes

RESTful Query API/Query OM

Yes

Yes

Yes

Yes

Result sources

Yes

Yes

Yes

Yes

Search connector framework

No

No

No

No

Search results sorting

Yes

Yes

Yes

Yes

Search vertical: “Conversations”

Yes

Yes

Yes

Yes

Search vertical: “People”

Yes

Yes

Yes

Yes

Search vertical: “Video”

No

Yes

Yes

Yes

“This List” searches

Yes

Yes

Yes

Yes

Hope this article helps. Please comment and rate the same.

SharePoint 2013 Designer Workflow – Creating a Custom Task Outcome – Assign Task to Specific User

Overview

Here we will see that how to create the custom task outcome. First we will see what that is and why the task outcome is so important.

Default Task Outcome

By default, if you assign a task to someone in SharePoint 2013 workflow, the task output will look likes below.

S1

But as per our helpdesk workflow requirement, while employee raise a ticket, the new task will be created and assigned to IT Admin user group. In this stage (Waiting for IT Admin Approval stage), he can either assign to Support Team for implement or assign back to Employee if there is any clarification and he is not going to approve or reject functionality. So our new task form output will be look like that,

S2

We need to follow the below steps for implementing the new requirement.

  1. Create a new Task Outcome Column
  2. Create a new Content Type
  3. Changes in Helpdesk Workflow
  4. Use the Task Outcome

Step 1: Create a new Task Outcome Column

We will create a new site column RequestClarificationOrAssign with the following values

2014-01-29_02

Step 2: Create a new Content Type

We will create a new site content type Request Clarification Or Assign – IT Admin View based onWorkflow Task (SharePoint 2013) Content Type. And then add a site columnRequestClarificaitonOrAssign with newly created content type.

2014-01-29_03

Now add this content type with Helpdesk Task list and the task list content type will look like,

2014-01-29_04

Step 3: Changes in Helpdesk Workflow

    1. Edit the Helpdesk WF workflow using SharePoint Designer 2013
    2. Inside the Waiting for Approval Stage, select the Assign a Task to IT Admin action
    3. Select the Task Properties
    4. Expand the Outcome Options
    5. Select the Task content type as Request Clarification Or Assign – IT Admin View
    6. So the output will look like below

2014-01-29_06

Save and republish the workflow. When we create the new task, the task output screen will look like below

2014-01-29_08

Step 3: Use the Task Outcome

IT Admin will click either the Request Clarification or Assign button. So we should capture the action using local variables and will use in If condition action

  1. Again select the Assign a Task to IT Admin action
  2. Select the Task Outcome
  3. Create the local variable ReqClarificationOrAssignOutcome

2014-01-29_07

4. Now edit the If condition next to Waiting for Approval stage

5. Set the local variable ReqClarificationOrAssignOutcome like below

2014-01-29_09

6. Based on the IT Admin action, the next stage will be either Request Clarification or Assign for Implementation

Summary

I hope that now we know how to create and use custom task outcome.

SharePoint Online – Sharing documents or collaborating directly with External users like vendors, clients or customers

Requirement:

SharePoint Online contents should be accessible to CAL users as well as to external non CAL users.

 

Solution:

Below figure depicts SharePoint Online contents are accessible to CAL users as well as to external who do not have licenses for your Microsoft Office 365 subscription,

External Users SharePoint Online

What are the external sharing features of SharePoint Online?

External sharing features include:

  • The ability to turn external sharing on or off globally for an entire SharePoint Online environment (or tenant).    Turning external sharing off at the tenant level means no documents, sites, or site collections can be shared externally.
  • The ability to turn external sharing on or off for individual site collections.    This provides you with the ability to secure content on specific site collections that you do not want to be shared.
  • The ability to share sites and documents with authenticated users.    Authenticated users are those who are invited to sign in by using a Microsoft account or work or school account.
  • The ability to share documents with guest users.    Guest users, also called anonymous users, don’t need a Microsoft account or work or school account to access documents. They access the document via a guest link that you or your employees give to them.

What is an external user?

An external user is someone outside of your organization who can access your SharePoint Online sites and documents but does not have a license for your SharePoint Online or Microsoft Office 365 subscription. External users are not employees, contractors, or onsite agents for you or your affiliates.

External users inherit the use rights of the SharePoint Online customer who is inviting them to collaborate. That is, if an organization purchases an E3 Enterprise plan, and builds a site that uses enterprise features, the external user is granted rights to use and/or view the enterprise features within the site collection they are invited to. While external users can be invited as extended project members to perform a full range of actions on a site, they will not have the exact same capabilities as a full, paid, licensed member within your organization. The limitations are described in the table below.

External Users Can… External Users Can’t…
Use Office Online for viewing and editing documents. If your plan includes Office Pro Plus, they will not have the licenses to install the desktop version of Office on their own computers. Create their own personal sites (what used to be referred to as My Sites), edit their profile, change their photo, or see aggregated tasks. External users don’t get their own OneDrive for Business document library.
Perform tasks on a site consistent with the permission level that they are assigned. For example, if you add an external user to the Members group, they will have Edit permissions and they will be able to add, edit and delete lists; they will also be able to view, add, update and delete list items and documents. Be an administrator for a site collection (except in scenarios where you’ve hired a partner to help manage Office 365. You can designate an external user as a designer for your Public Website.

NOTE: The SharePoint Online Public Website information in this article applies only if your organization purchased Office 365 prior to March 9, 2015. If you purchased Office 365 after March 9, 2015, use an Office 365 website hosting partner.

See other types of content on sites. For example, they can navigate to different subsites within the site collection to which they were invited. They will also be able to do things like view site feeds. See the company-wide newsfeed
Add storage to the overall tenant storage pool
Access the Search Center or execute searches against “everything.” Other search features that may not be available include: Advanced Content Processing, continuous crawls, and refiners.
Access site mailboxes
Access PowerBI features such as Power View, Power Pivot, Quick Explore, or Timeline Slicer. These features require an additional license, which is not inherited by external users.
Use eDiscovery. This requires an Exchange Online license.

Open downloaded documents that are protected with Information Rights Management (IRM).

Other features that might not be available to external users are:

  • Excel Services features, including Calculated Measures and Calculated Members, decoupled Pivot Tables and PivotCharts, Field List and field support, filter enhancements, search filters.
  • SharePoint Online data connection libraries
  • Visio Services

Deciding how to share

External sharing is turned on by default for your entire SharePoint Online environment (sometimes referred to as a tenant) and the site collections in it. You may want to turn it off globally before people start using sites or until you know exactly how you want to use the feature.

You have a lot of flexibility when enabling external sharing so you’ll want to spend some time considering your options. For example, you can enable sharing across the tenant, which gives all users the ability to share. You can limit sharing to certain site collections so only those site collection administrators and administrators of sites within those collections can invite external users. You can also limit the ability to share sites and documents to a select group of users.

When considering if and how you want to share content externally, think about the following:

  • To whom do you want to grant access to content on your team site and any subsites, and what do you want them to be able to do?
  • To whom in your organization do you want to grant permission to share content externally?
  • Is there content you want to ensure is never available to be viewed by people external to your organization?

The answers to these questions will help you plan your strategy for content sharing.

Try This: If You Need To:
Share a site

If you want to share a site, but you also want to restrict external users from gaining access to some of your organization’s internal content, consider creating a subsite with unique permissions that you use exclusively for the purpose of external sharing. Similarly, if you want to share a subsite that you’ve created on your OneDrive for Business location, you might want to ensure that it also has unique permissions so that you do not accidentally grant users permission to additional sites or content on your OneDrive for Business site.

SharePoint uses a permissions inheritance model where new sites automatically inherit permissions from their parent sites. By assigning unique permissions to subsites you are “breaking” the inheritance chain. To learn more about permissions inheritance, seeWhat is permissions inheritance?

Provide someone outside your organization with ongoing access to information and content on a site. They need the ability to perform like a full user of your site and create, edit, and view content.
Share a document and require sign-in. Provide one or several people outside your organization with secure access to a specific document for review or collaboration, but these people do not require ongoing access to other content on your internal site.
Share a document, but don’t require sign-in. Share a link to a non-sensitive or non-confidential document with people outside your organization so that they can either view it or update it with feedback. These people do not require ongoing access to content on your internal site.

Note that if you share documents using anonymous guest links, then it’s possible for invitation recipients to share those guest links with others who could use them to view content.

You should include planning for external sharing as part of your overall permissions planning for SharePoint Online. In general, it’s a best practice to operate on the “principle of least privilege” and grant external users minimal and limited access to your environment. You may even want to create a special permissions group to which external users are assigned when they receive invitations. You should also consider segmenting your content by security levels, so that sensitive content is centrally located and can be tightly secured. If you anticipate an ongoing need to have external users log in to your site and perform specific tasks consider creating a site collection that is dedicated to the purpose of external sharing. This way, you can allow external users access to specific content without opening up your entire environment to them.

For more information about planning for permissions, see Plan your permissions strategy.

Turn external sharing on or off for individual site collections

You must be a SharePoint Online admin to configure external sharing for individual site collections. Site collection administrators are not allowed to change external sharing configurations.

  1. From the SharePoint admin center, click site collections.
  2. Check the box next to those site collections whose sharing settings you want to turn on or off.
  3. In the ribbon, click Sharing.

    ribbon from SharePoint Online admin center with Sharing button highlighted

  4. Do one of the following:
If You Want To: Select This Option: For This Result:
Prevent all users on all sites from sharing sites or sharing content on sites with external users. Don’t allow sharing outside your organization
  • Users will not be able to share sites or content in this site collection with users who do not have licenses to your Office 365 subscription.
  • If sharing was previously turned on for this site collection, any external users who were invited to sign-in and view content on sites in this site collection will be permanently deleted.
  • If you ever plan to turn on external sharing for this site collection again, these external users would need to be re-invited.
Require external users who have received invitations to view sites or content to sign-in with a Microsoft account before they can access the content. Allow external users who accept sharing invitations and sign in as authenticated users
  • Site owners or others with full control permission can share sites with external users.
  • Site owners or others with full control permissions on a site can share documents with external users by requiring sign-in.
  • All external users will be required to sign in before they can view content.
  • Invitations to view content can be redeemed only once. After an invitation has been accepted, it cannot be shared or used by others to gain access.
Allow site users to share sites with people who sign in as authenticated users, but you also want to allow site users to share documents through the use of anonymous guest links, which do not require invited recipients to sign in. Allow both external users who accept sharing invitations and guest links
  • Site owners or others with full control permissions can share sites with external users.
  • All external users will be required to sign in before they can view content on a site that has been shared.
  • Site owners or others with full control permissions can also share documents externally opt to require sign-in, or send an anonymous guest link for documents.
  • When users share a document, they can grant external users either view or edit permissions to the document.
  • External users who receive anonymous guest links can view or edit that content without signing in.
  • Anonymous guest links could potentially be forwarded or shared with other people, who might also be able to view or edit the content without signing in.

NOTES:

  • If external sharing is turned off for the entire SharePoint Online environment, you will not be able to turn it on for specific site collections.
  • The external sharing settings for individual site collections cannot be less restrictive than whatever is allowed for the entire SharePoint Online environment, but these settings can be more restrictive. For example, if external sharing is turned on for the entire SharePoint Online environment, but it is limited to allowing only authenticated users, then that will be the only kind of external sharing you can allow in a specific site collection. If external sharing through both sign-in and anonymous guest links is allowed for the entire SharePoint Online environment, you can opt to turn off external sharing entirely for a specific site collection or you can limit external sharing to authenticated users (no guest links).
  • If external sharing is turned off globally in the SharePoint Online Admin center, any shared links will stop working. If the feature is later reactivated, these links will resume working. It is also possible to disable individual links that have been shared if you want to permanently revoke access to a specific document.
  • If you change the external sharing settings for the My Site site collection, these changes will also apply to any existing or newly created personal sites (formerly called My Sites).
  • Sharing settings on the –my site site collection (e.g., https://contoso-my.sharepoint.com) will apply to the OneDrive for Business sites for all users of the organization. You cannot selectively manage sharing for a particular user’s OneDrive for Business site.

View external sharing settings for site collections

To quickly view the external sharing settings for a group of site collections:

  1. From the SharePoint admin center, click site collections.
  2. Check the box next to those site collections whose sharing settings you want to check.
  3. In the ribbon, click Sharing.
  4. Scroll through the list of URLs to see sharing settings for each site collection.

    sharing dialog showing settings for two site collections

Turn external sharing on or off for individual site collections

You must be a SharePoint Online admin to configure external sharing for individual site collections. Site collection administrators are not allowed to change external sharing configurations.

  1. From the SharePoint admin center, click site collections.
  2. Check the box next to those site collections whose sharing settings you want to turn on or off.
  3. In the ribbon, click Sharing.

    ribbon from SharePoint Online admin center with Sharing button highlighted

  4. Do one of the following:
If You Want To: Select This Option: For This Result:
Prevent all users on all sites from sharing sites or sharing content on sites with external users. Don’t allow sharing outside your organization
  • Users will not be able to share sites or content in this site collection with users who do not have licenses to your Office 365 subscription.
  • If sharing was previously turned on for this site collection, any external users who were invited to sign-in and view content on sites in this site collection will be permanently deleted.
  • If you ever plan to turn on external sharing for this site collection again, these external users would need to be re-invited.
Require external users who have received invitations to view sites or content to sign-in with a Microsoft account before they can access the content. Allow external users who accept sharing invitations and sign in as authenticated users
  • Site owners or others with full control permission can share sites with external users.
  • Site owners or others with full control permissions on a site can share documents with external users by requiring sign-in.
  • All external users will be required to sign in before they can view content.
  • Invitations to view content can be redeemed only once. After an invitation has been accepted, it cannot be shared or used by others to gain access.
Allow site users to share sites with people who sign in as authenticated users, but you also want to allow site users to share documents through the use of anonymous guest links, which do not require invited recipients to sign in. Allow both external users who accept sharing invitations and guest links
  • Site owners or others with full control permissions can share sites with external users.
  • All external users will be required to sign in before they can view content on a site that has been shared.
  • Site owners or others with full control permissions can also share documents externally opt to require sign-in, or send an anonymous guest link for documents.
  • When users share a document, they can grant external users either view or edit permissions to the document.
  • External users who receive anonymous guest links can view or edit that content without signing in.
  • Anonymous guest links could potentially be forwarded or shared with other people, who might also be able to view or edit the content without signing in.

NOTES:

  • If external sharing is turned off for the entire SharePoint Online environment, you will not be able to turn it on for specific site collections.
  • The external sharing settings for individual site collections cannot be less restrictive than whatever is allowed for the entire SharePoint Online environment, but these settings can be more restrictive. For example, if external sharing is turned on for the entire SharePoint Online environment, but it is limited to allowing only authenticated users, then that will be the only kind of external sharing you can allow in a specific site collection. If external sharing through both sign-in and anonymous guest links is allowed for the entire SharePoint Online environment, you can opt to turn off external sharing entirely for a specific site collection or you can limit external sharing to authenticated users (no guest links).
  • If external sharing is turned off globally in the SharePoint Online Admin center, any shared links will stop working. If the feature is later reactivated, these links will resume working. It is also possible to disable individual links that have been shared if you want to permanently revoke access to a specific document.
  • If you change the external sharing settings for the My Site site collection, these changes will also apply to any existing or newly created personal sites (formerly called My Sites).
  • Sharing settings on the –my site site collection (e.g., https://contoso-my.sharepoint.com) will apply to the OneDrive for Business sites for all users of the organization. You cannot selectively manage sharing for a particular user’s OneDrive for Business site.

Turn external sharing on or off for a SharePoint Online environment (tenant)

You must be a SharePoint Online administrator to configure external sharing.

  1. From the SharePoint admin center, click settings.
  2. In the External sharing section do one of the following:
If You Want To: Select This Option: For This Result:
Prevent all users on all sites from sharing sites or content with external users. Don’t allow sharing outside your organization
  • Users will not be able to share sites or content with users who do not have licenses to your Office 365 subscription.
  • External sharing cannot be turned on for any individual site collections.
Require external users who have received invitations to view sites or content to sign-in with a Microsoft account before they can access the content. Allow external users who accept sharing invitations and sign in as authenticated users
  • Site owners or others with full control permission can share sites with external users.
  • All external users will be required to sign in before they can view content.
  • Invitations to view content can be redeemed only once. After an invitation has been accepted, it cannot be shared or used by others to gain access.
Allow site users to share sites with people who sign in as authenticated users, but you also want to allow site users to be able to share documents through the use of anonymous guest links, which do not require invited recipients to sign in. Allow both external users who accept sharing invitations and guest links
  • Site owners or others with full control permissions can share sites with external users.
  • All external users will be required to sign in before they can view content on a site that has been shared.
  • Site owners or others with full control permissions can share documents and opt to require sign-in, or send an anonymous guest link for documents.
  • When site users share a document, they can grant external users either view or edit permissions to the document.
  • External users who receive anonymous guest links can view or edit that content without signing in.
  • Anonymous guest links could potentially be forwarded or shared with other people, who might also be able to view or edit the content without signing in.

NOTES:

  • If you turn off external sharing for your entire environment and later turn it back on, external users who previously had access to content or documents on sites will regain access to them. If you know that external sharing was previously turned on and in use for specific site collections and you do not want external users to be able to regain access if external sharing is ever turned on again globally, we recommend that you first turn off external sharing for those specific site collections.
  • When you turn off external sharing at the site collection level, all external user permissions for that site collection will be permanently deleted.
  • When you turn off external sharing at the site collection level, guest links will be disabled, but they could start working again if external sharing is ever turned on again. If you want to permanently revoke access to specific documents, you will need to disable the anonymous guest links.
  • If you disable external access, or limit external access to a more restrictive form, external users will typically lose access within one hour of the change.

Manage external user accounts and invitations

Once external sharing has been enabled for the tenant and/or site collection and sharing permissions established, authorized users can send invitations, create guest links, and revoke access, and so on. For complete instructions, see Share sites or documents with people outside your organization.

NOTES:

  • There is no global way to see a list of all the sites to which an external user has access. You need to go to the individual sites to determine whether a specific user has access to it
  • There is also no global way to see a list of all documents that have been shared externally.

    While you can’t do this in SharePoint Online, you can use the Compliance Search feature in the Compliance Center to do both of these things, by using the ViewableByExternalUsers property in a search query. For more information, seeSearching for site content shared with external users.

 

 

Use Windows PowerShell to control how external sharing invitations can be accepted

You can use Windows PowerShell to turn external sharing on or off. Using the SharePoint Online Management Shell, administrators can now enforce new controls over how external users accept invitations. When enabled, the RequireAcceptingAccountMatchInvitedAccount parameter requires external users to accept invitations with the email account with which they originally received the invitation.

  • If this parameter is not set or is set to null:

    When a user shares with an external user, they enter an e-mail like stephen@contoso.com, and an email is sent to Stephen at stephen@contoso.com. When he attempts to accept the invitation (by clicking the link in the email), he can log in with any account he wants to use. For example, he could use stephen@contoso.com, stephen@live.com, or even dwight@contoso.com. The sharing email can be forwarded and accepted by anyone. This system ensures that external users who use email aliases or who do not have a Microsoft account or organization account are able to accept the invitation.

  • If this parameter is set to true:

    The RequireAcceptingAccountMatchInvitedAccount parameter ensures that the user who receives the invitation is also the user who accepts it. If an invitation is sent to stephen@contoso.com, only a user who can log into stephen@contoso.com is able to accept the invitation. Any other email account displays an error page that directs to user to use the appropriate account.

Notes that this does not apply to invitations that have previously been accepted in SharePoint Online and it only affects external sharing invitations that are generated after the parameter has been set. It will also not affect external users who have previously accepted an invitation. They will be able to log-in and use the system as normal. This feature does not work with e-mail aliases.

For detailed information about the cmdlet and parameters in Windows PowerShell, see Set-SPOTenant.

Copy files not older than 15 min using PowerShell Script

 

Requirement

There is requirement of copying files as old as 15 min to an destination folder. Older than 15 min files should be retained at the source location.

Solution

Below is the simple PowerShell based code to achieve the above requirement.

Fetch all files from a specific folder with metadata

Get-ChildItem “C:\Amjad\SourceFiles\” -File | select name, *time

PS1

Fetch files only as old as 15 minutes

Get-ChildItem  -Path “C:\Amjad\SourceFiles\*” | where {$_.LastWriteTime -ge (Get-Date).AddMinutes(-15)} | select name, *time

PS2

 

Copy the files only as old as 15 minutes to Destination folder

Get-ChildItem  -Path “C:\Amjad\SourceFiles\*” | where {$_.LastWriteTime -ge (Get-Date).AddMinutes(-15)} | Copy-Item -Destination C:\Amjad\ArchivalDestination

 

Similarly if you want to move all files by Creation time to be copied to destination folder,

Get-ChildItem  -Path “C:\Amjad\SourceFiles\*” | where {$_.CreationTime -ge (Get-Date).AddMinutes(-15)} | Copy-Item -Destination C:\Amjad\ArchivalDestination

 

Similarly if you want to move all files by Last Access time to be copied to destination folder,

Get-ChildItem  -Path “C:\Amjad\SourceFiles\*” | where {$_.LastAccessTime -ge (Get-Date).AddMinutes(-15)} | Copy-Item -Destination C:\Amjad\ArchivalDestination

Hope this article would be useful.

 

 

How to add calendar WebPart with a calendar view on SharePoint Online – O365

I have came across many people around seeking help on Calendar WebPart with Calendar view to be displayed on specific page.

This solution is applicable to SharePoint Online, SharePoint 2010, SharePoint 2013.

So here are step by step approach to the same.

Step 1 :  Create a Event Calendar to Site Content by using Event Calendar as template,

1

Step 2: Add few events to it as highlighted

2.1

Step 3: Set current view as “Calendar” as highlighted in below figure,

2.1

Step 3: Go to the page where you want to add the calendar view webpart and edit the page.

Step 4: Add the list webpart as highlighted below,

3

Step 5: Click on Add button

Step 6: Now you can see that the desired view is displayed on your page as below,

4

Hope this is useful for you.

O365 – Hybrid Exchange – Mailboxes remain within O365 – Issue of accessing the Exchange public folders of SharePoint 2007 and SharePoint 2013 – unable to expand them

Mailscape_Office_365

Scenario:

Tenant has an onPrem environment which consists of Exchange 2007 servers and two Exchange 2013 hybrid servers. The hybrid servers are set up to allow users to migrate to O365 and users in O365 to have the ability to access resources from the onPrem environment. The public folders are in the 2007 environment and were set up properly according to the following article:

https://technet.microsoft.com/en-us/library/dn249373(v=exchg.150).aspx

2007 and 2013 users have no issues accessing any of the legacy public folders, however, when an O365 user attempts to access the public folders, they are unable to expand them. They get the following error:

“Cannot expand the folder. Microsoft Exchange is not available. Either there are network problems or the Exchange server is down for maintenance.”

How to Troubleshoot this issue:

The first thing you want to understand is what is happening with the requests when they leave outlook and go into the Exchange environment. To do this, you will need the fiddler tool. Fiddler can be downloaded from the following location:

Download Fiddler

Once Fiddler is installed, start it up and then reproduce the problem, by starting outlook with the O365 account and trying to expand public folders. We are looking for any 401 statuses against the Hybrid namespace when using the /rpc/rpcproxy.dll?servername.contoso.com:6001 URL. It should look similar to the following (minus the redactions of course):

UPN-LegacyPF-Fiddler

So what do we know so far:

  • When we attempt to expand the legacy public folders, we are getting a 401 Unauthorized error. This means the account we are logging in with does not have permissions to access the public folder, or the account it is using is not recognized by the OnPrem active directory environment.
  • We know the Unauthorized request is spawned by they Hybrid server as it tries to connect to the legacy folders (which is a netlogon connection).
  • We know the users who are on OnPrem are not having this issue regardless of whether they are on 2007 or 2013. If 2013 users didn’t work, we would suspect there was something wrong with the proxy request back to the 2007 public folders, possibly a MaxConcurrentAPI issue, but in this scenario, that is not the case.

What don’t we know yet?

Why exactly are we getting Unauthorized when our environment appears to be set up properly?

To answer this, we need more logging. In this case, we need the Netlogon logs on the Hybrid servers. By default, the Netlogon logs are disabled, so we first need to enable them. To do that, simply fire up command prompt (as administrator) and run the following commands. Netlogon will be restarted in this process:

Nltest /DBFlag:2080FFFF

net stop netlogon && net start netlogon

That full process is described in the following article:

Enabling debug logging for the Netlogon service

Now, with Netlogon logging enabled, we will reproduce the issue again and see what we see.

Within the Netlogon logs, we see the following error:

06/17 13:36:07 [CRITICAL] [5468] NlPrintRpcDebug: Couldn’t get EEInfo for I_NetLogonSamLogonEx: 1761 (may be legitimate for 0xc0000064)

The 0xc0000064 error means that the account does not exist. Now why would AD think the account does not exist?

We looked at the account they were logging into Outlook with. It was user@contoso.com. We then looked at the OnPrem mail user for that account and it had a primary SMTP address of user@contoso.com, but its UPN was @contoso.org. When we tried to change the UPN onPrem to match the primary SMTP address, the UPN drop down box did not have @contoso.com listed. This told me that no alternative UPN suffix was set up for that domain onPrem. They had it as an accepted domain so it could receive email, but not as an UPN so it couldn’t be used for permissions onPrem, hence the 401 unauthorized.

To verify, we then went into Active Directory Domains and Trust and checked to see if it had any alternative UPN suffixes set. To do this, once in Active Directory Domains and Trusts, you right click on Active Directory Domains and Trusts (you do not need to expand it), and then click on properties. Should look as follows (no redaction in this one as it is from my test lab):

ADDT

The Fix:

As you can see, there are no Alternative UPN suffixes. We need to add the contoso.com domain to the Alternative UPN suffixes so the O365 user’s onPrem mail user account can have it selected as their UPN.

Once the UPN was added to the Alternative UPN Suffixes, we waited for AD replication to complete and then went back into the user account onPrem and changed it’s UPN to match that of the Primary SMTP address which is what is used by the O365 user to log in. Again we waited for AD to replicate, which didn’t take long as they only had one site, so pretty much instantly.

After that the O365 user was able to expand and use the legacy public folders.

Note:

Other issues can occur when the alternative UPN suffixes are not set with the remaining SMTP domains used by your organization. Lately, in addition to legacy public folder access from O365, we have seen the issue manifest when an application does authenticated relaying using the SMTP address of the service account. If that SMTP address does not have UPN suffix associated with it, it will reject the connection as unauthorized.

The following KB article discusses the two methods of changing the UPN on a user account. In our scenario, we went with option 2.

Changes aren’t synced by the Azure Active Directory Sync tool after you change the UPN of a user account to use a different federated domain

Hopefully, you will find this article useful as more and more organizations get off of the legacy environments, easing their transition.