Wednesday, September 2, 2020

Copy SharePoint files and retain Created By and Modified using a Power Automate Flow

 The Problem

 I've seen crop up in searches and I have seen it on Microsoft Tech community where people want to copy files somewhere for multitude of reasons but want to retain the created by and modified by information. Current methods do not retain information when a copy is used. 

Existing Methods

Using a Power Automate Flow's built in "Copy File" copies files across sites and libraries no problem. However, the person triggering the flow or the account the trigger is built on becomes the created by / modified by after the copy completes since it's creating a new file for the copy. 

The "Move file" action works, but it does not retain the original file in it's original location which is a requirement in many cases when copying files somewhere for archive or other purposes. 

CreateCopyJobs to the Rescue

After looking around for REST calls that might work, I stumbled across the newer option which utilizes the same mechanics that "Move to" and "Copy to" use in SharePoint Modern pages. I thought originally that "Copy to" retained metadata but after testing it, it does not. I started looking at the properties for this call and noticed at the very end a property called "MoveButKeepSource"

public bool MoveButKeepSource { get; set; }

Once set, this move operation is similar to copy. The file will move to destination, but the source content will not be deleted. If set, this will make a copy with the version history and preserve the original metadata. No source item deletions occurs at the end.

Well, this is interesting. What this means is we can basically use the Move method but retain the original which in effect acts as a copy, but it will retain the metadata like a move to will. This is perfect! Now how do we get that into effect?  

Here is a reference to the CreateCopyJobs Docs article. 

The Flow

This is a very simple 2 step flow. Step 1 is the trigger, either a manual method using "For selected item" or you can have it automatically copy based on created / modified of files in a library. Step 2 is a "Send HTTP Request to SharePoint" action. 

Below is my  example flow that I used to get this working.

Here is the Body I used for this update, I hardcoded the destination and what not but if you need to make this dynamic for some reason you could easily do this. Just make sure you input your destination URL to the library without the trailing / as you will get an error if you include that. 

   ],   "destinationUri":"",

I have the options set so that version history moves over, movemode tells this to use move instead of copy which will retain metadata, MoveButKeepSource is the key that keeps a copy and moves a copy. AllowSchemaMismatch is you have different columns in the libraries, I put this in as any changes to columns and you will get a badgateway error so best to have this in place. NameConflictBehavior is 1, this will replace existing files with the same name. If you want to create a copy instead you can specify a 2 and it will append a number to the end of the document name. 


I hope this helps anyone out there that has this requirement of copying files somewhere and wanting to retain metadata from an automated method or you just want to copy files and retain the Created by / Modified  by columns since utilizing the built in "Copy to" doesn't seem to do that. 

Friday, March 6, 2020

Microsoft Teams Suggested and Trending Notifications and How They Can Cause Confusion

New Suggested and Trending Notifications in Microsoft Teams

Microsoft has started to sneak in a feature into Teams that gives notifications for trending and suggested threads throughout your various Teams you are a member of. These are notifications to help you get more involved and not miss out on content in your Teams designed to help you reduce notification settings and keep you in the loop but it seemingly is causing more confusion than it is helping users with their Teams and notification noise.

Why Are Notifications Showing for Channels That Are Set Off?

There are many Tech Community posts and mumbling about that users are getting confused because they are receiving notifications in their activity feed despite them setting these channels notifications to "off".

On close inspection, you will notice that these notifications have new icon's next to them to let you know what the source of the notification is. Instead of the usual icons for reply, mention etc. you will have the following new icon's for Suggested and Trending notifications in the feed. 

These types of notifications do not follow the same rules as your channel notification settings and can make it seem that your notification settings are not working even thou they are for the normal notification types, but these new notification types override your settings. 

How can I disable these? 

Luckily Microsoft has provided ways of disabling these notification if you do not want them. Below you can find out how you can disable this for yourself. Or how the tenant admin can disable these for everyone with the click of a mouse. 

Per User: 

Each user has the ability to disable the suggested and trending notifications in their notification settings. In the settings window on the notifications tab, you can find trending and suggested as shown and set how you wish to be notified of these actions. **If you do not have these they have not been pushed to your tenant**


Your tenant admins have the option to disable this for all users by disabling the following feature in Org Wide Settings > Team Settings > Notification and Feeds section, You have an option to disable Suggested feeds which should include Trending and Suggest notification types. This should disable it for your entire Org. 

Hopefully this will help you when this feature lands and your users are confused to why they are getting notifications for posts they shouldn't be getting them for. This feature can help with setting up less notifications but stay up on trending topics, however most users are used to being in control of what they want and don't want to see. The good news is Microsoft has given us a choice in this matter and not forced the notifications on us, so good job Microsoft for that, I just wish it was a bit more obvious than an icon to the users why they are getting these seemingly random notifications in their feeds.  

Tuesday, January 7, 2020

Document Library comes up blank in SharePoint Online with Chrome

I have been noticing a few users getting blank pages when navigating to a Document Library in SharePoint Online. The issue is random, but seems to have been happening more frequently. I don't know if it's a Chrome update or SPO Update that is causing the issue, but I finally got a moment to sit down and figure out the easy fix for the problem.

You can switch browsers and the problem goes right away so it is not a service issue itself but related directly with Chrome. To fix the problem ,you simply have to clear out the site settings cache in chrome for SharePoint Online. You could clear out the entire cache, but it's not necessary. 

Clear Site Settings Cache
To clear out the site setting cache do the following.
1. Go into Chrome Settings
2. Click Advanced
3. Click on Privacy and services
4. Click "Site Settings" section
5. Under All Sites at the top click "View permissions and data stored across sites"
6. Locate and click the verticle ... menu and clear data.

This will clear the site data and should restore the usage of your document libraries.

Friday, June 7, 2019

Microsoft Teams Guest Users Chat Tab Missing

Been seeing some rumblings around Tech Community about guests not being able to chat in Microsoft Teams even thou Guest settings are set to allowed. After some troubleshooting and testing I had a hunch that it could be the coexistence mode settings and sure enough it was.

Cause: Skype Coexistence Modes

In my test scenario I switched my tenant over from Teams Only to Skype Only and waited overnight, and I woke up to a missing chat tab with my guest user. So we definitely have a root cause for the issue. The question is it by design? I Expect the other two Skype coexistence modes to also effect chat for guests.

Work Around: Teams Only Coexistence Mode

A work around would be to set your users that should be Skype Only manually to Skype Only coexistence mode per user. Once this is set, I personally would give it some time to bake. Next switch your Org setting to Teams Only. This should now revert the guest user to be able to chat and maintain your users upgrade mode.

The side effect to this method is your new users will be provisioned into Teams Only mode. So you would have to remember to change their coexistence mode when creating their accounts. This could also cause delays in the message routing as well so you will want to plan accordingly.


So far I haven't received any feedback on this item but I do not think it's by design. Not sure if it will get fixed or not, but right now the work around is the only method for allowing guests to have chat. This seems to have started appearing recently since the updates to the Coexistence Modes starting to enforce their intended behaviors (Disabling chat etc.). 

If I get anymore information about this I will update this blog. 

Saturday, February 23, 2019

Updated Teams Out of Office Presence Behavior

Recently I went on a few day vacation and happen to notice some new changes to how presence works when Microsoft Teams automatically sets your status to "Out of Office" while using Automatic Replies or adding Out of Office meetings to your Exchange Online calendar.

Lets take a quick dive into the history of this feature and what has changed.

Previous Exchange Online OOF Presence Integration

Back in April of last year Teams released an update that would set your Teams status to Out of Office anytime you set Automatic Replies via Outlook/OWA or scheduled an appointment on your calendar with the "Show as" set to "Out of Office". This would hold your status as "Out of Office" throughout the duration of the event with the purple icon along with your Automatic reply if one existed shown below

Many users would complain that they couldn't change their status and that they were traveling for work and originally were confused by this when it first hit Teams. I never realized how many people used meetings in their calendars to block off their Out of Office until this feature launched. This caused some behaviors to be adjusted and left many with frustration of how this forced effect worked. The Teams team seems to have taken a good step closer to solving these exact scenarios.

Updated Exchange Online OOF Presence Integration

I'm not 100% sure when this feature came into play, but I would bet it was with the custom status update recently since this new integration disables the custom status so I think it makes use of it to make this work in this new way.

When you set your Automatic responses or OOF calendar meeting, when Teams polls this information (seems to be roughly every hour) it will now set your status in Teams to a new %CurrentStatus% - Out of Office format. What this means is you can now set your status to Available/Busy/DnD while OOF is active and you will get new status icons (white background) indicating your current status. You also get the same Automatic Reply message as well on hover cards.

Your status is set to the default purple icon and "Out of Office" status for all away statuses including being idle.

The new out of office statuses in Teams: 

What this means is you can now be out of the office and actually see if people are available for communication. This comes in handy in scenarios where people are out of home base, but traveling to customer sites and set their OOF for the trip and they still want their availability to show to colleagues. This is also useful if you want to to show your availability because you don't manage your work life balance properly and for some reason want to work when you're on vacation :).

Other Exchange Online Presence Integration 

It doesn't appear that the other presence integrations have been messed with at this point, such as your status being set to Busy when you have a meeting in your calendar etc. I

t's good to see Microsoft starting to tweak and improving some of the little things throughout the Teams product and hopefully we will see many more like it in the coming months.

Have questions? The best place to reach me or other Teams experts is the Teams Microsoft Tech Community.

Follow me on Twitter: @chriswebbtech

Wednesday, December 5, 2018

Microsoft Teams Reply / New Conversation Ideas

Recently @suphatra posted up an update to the uservoice for Better visual delineation between reply and new conversation.  with a survey requesting us to vote on what we liked best. Frankly, myself  along with many others are not happy with the results of any of the options. I picked the "New Conversation" button as the better of the 3 but I think we really need to step back and think what really could make this experience better than just a button.

Sure the button would improve unwarranted replies from what they were before but I think it could be done better. Here are a couple quick mock ups that I think would do a better job than just a button. Some of these might not be technical feasible and require a lot more work than it's worth but I'm putting them out there anyway. 

Idea 1 - New Button, Update Reply

So for this, I just made the reply button a text box by default, instead of clicking reply, most users are going to see the bottom text box and think hey I'm used to using that form chat, and then they click into it to use instead. 

I've also removed the New conversation Textbox and made the button. These two things will have more impact than just the button alone. 

*** New conversation button also needs to take user view to bottom of Conversation history, so that they can see their new conversation is going to go at the bottom. Currently it stays where you are in relation to what you are reading, sometimes causing reply buttons to line up with the New conversation textbox which causes users to use the wrong box, the new button should solve this use case thou.  

Idea 2 - Updated Reply with Toolbar

Second Idea, Add a Toolbar similar to what we'll have on the files tab with SharePoint UI. With New Conversation Button, Meet Now, Messaging Extension and Even Follow. You could even add a Drop down on it for "Channel Roster" (People who favorite) the channel. 

When clicking New conversation, cursor jumps To bottom where the conversation would go inline with the other Threads, and you are editing in place what the thread looks like instead of working from a textbox on the bottom. 

Friday, November 30, 2018

Use mailto: and other link types with the Quick Links Modern Web Part

More link types, more flexability

The SharePoint Online quick links webpart is a great webpart. It lets you quickly and easily put a variety of nice graphical links to other related resources throughout your intranet or even the internet.  

The issue is however the links are limited to only https URLs and sometimes you may want a link to send an e-mail, chat or place a call to someone such as the helpdesk. Since these link types are not supported you really don't have much of a way to accomplish this and it is a fairly common ask I've seen on the Microsoft Tech Community over the months. 

Where There is a Will there is a Way (UserVoice)

Currently there is a uservoice for this option to add support for mailto: links in quick links. I hope they add more than just that if they ever do update it because I would like to do things like add SIP addresses for chat, tel: for calls etc. which I will also be covering here in a minute. The link to the uservoice is here, go vote if you found this article and are reading this :) 

URL Shortening to the Rescue

So when I see this come up, I let people know the best way around this is to make use of a URL shortening service. There are a whole host of them out there. Make sure you find one that supports any type of link translation. The only I found and go working is Setting a URL is simple and straight forward. Just type in for the e-mail link and click the Shorten button. 

Copy the returned URL and use this URL on your quick links webpart on your SharePoint page. 
Now clicking the quick link will open a new e-mail message using your default mail client! 

Quick Links for Chat

Creating links to chat with a chat contact is handled pretty much the same way as using mailto: e-mail links. To setup a chat use for your link to shorten. This will open the default chat app and chat with the person with a click of the mouse! For all your Microsoft Teams Organizations this is a great way to have an article with a call out link to chat with someone instead of sending an e-mail! 

I know it's a simple task but sometimes the obvious doesn't show up for us, when an easy solution is there for the taking! Hopefully this helps a few folks out to get desired results!