<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:sy="http://purl.org/rss/1.0/modules/syndication/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:media="http://search.yahoo.com/mrss/">
<channel>
<title>DisplayFusion RSS: Loading monitor profiles when docking / undocking Microsoft Surface</title>
<atom:link href="https://www.displayfusion.com/Discussions/RSS/?TopicID=81c3c362-4e73-463a-9dea-12ab2797ec5f" rel="self" type="application/rss+xml" />
<link>https://www.displayfusion.com/Discussions/RSS/?TopicID=81c3c362-4e73-463a-9dea-12ab2797ec5f</link>
<description>DisplayFusion RSS: Loading monitor profiles when docking / undocking Microsoft Surface</description>
<lastBuildDate>Wed, 08 Apr 2026 04:46:28 GMT</lastBuildDate>
<language>en</language>
<sy:updatePeriod>hourly</sy:updatePeriod>
<sy:updateFrequency>1</sy:updateFrequency>
<generator>https://www.displayfusion.com/Discussions/RSS/?TopicID=81c3c362-4e73-463a-9dea-12ab2797ec5f</generator>
<item>
<title>RE: Loading monitor profiles when docking / undocking Microsoft Surface</title>
<link>https://www.displayfusion.com/Discussions/View/loading-monitor-profiles-when-docking-undocking-microsoft-surface/?ID=81c3c362-4e73-463a-9dea-12ab2797ec5f#9</link>
<pubDate>Tue, 25 Jul 2017 11:33:37 GMT</pubDate>
<dc:creator>Binary Fortress Software</dc:creator>
<guid isPermaLink="false">https://www.displayfusion.com/Discussions/View/loading-monitor-profiles-when-docking-undocking-microsoft-surface/?ID=81c3c362-4e73-463a-9dea-12ab2797ec5f#9</guid>
<category>DisplayFusion</category>
<description><![CDATA[Thanks Pablo
I tried your script and variances on it, but I'm still having problems loading profiles automatically.
I still have to manually select profiles when docking the surface at another desk. I think what may be confusing things, is when Surfaces are docked for the first time, the screen...]]></description>
<content:encoded><![CDATA[<div class="CTDiscussions">
Thanks Pablo<br/>
<br/>
I tried your script and variances on it, but I'm still having problems loading profiles automatically.<br/>
<br/>
I still have to manually select profiles when docking the surface at another desk. I think what may be confusing things, is when Surfaces are docked for the first time, the screens are cloned. What monitor id would this be? If I could run a function to detect this monitor id, then I could set a profile to launch.<br/>
<br/>
Thanks
</div>
]]></content:encoded>
</item>
<item>
<title>RE: Loading monitor profiles when docking / undocking Microsoft Surface</title>
<link>https://www.displayfusion.com/Discussions/View/loading-monitor-profiles-when-docking-undocking-microsoft-surface/?ID=81c3c362-4e73-463a-9dea-12ab2797ec5f#8</link>
<pubDate>Mon, 24 Jul 2017 12:00:29 GMT</pubDate>
<dc:creator>Binary Fortress Software</dc:creator>
<guid isPermaLink="false">https://www.displayfusion.com/Discussions/View/loading-monitor-profiles-when-docking-undocking-microsoft-surface/?ID=81c3c362-4e73-463a-9dea-12ab2797ec5f#8</guid>
<category>DisplayFusion</category>
<description><![CDATA[For DF 8.1.2 you can use something like that.
Code
Copy
Select All
using System;
public static class DisplayFusionFunction
{
public static void Run(IntPtr windowHandle)
{
var count = 0;
var monIDs = BFS.Monitor.GetMonitorIDs();
foreach (var mon in monIDs)
count ++;
if (count.Equals(1...]]></description>
<content:encoded><![CDATA[<div class="CTDiscussions">
For DF 8.1.2 you can use something like that.<br/>
<div id="" class="col-md-12 BoxWrap"><div class="Box table-responsive"><a name="code" style="width:0; height:0;"></a><h2 class="TableTitle" style="border:0"><div class="TableTitleText">Code</div><div class="TitleButtons"><div class="TableTitleButton"><a href="#" onclick="return false;" data-clipboard-target="#code019d6b69cb6c73d6b65007ceb98ee790" class="ClipboardCopyControl"><img src="https://www.displayfusion.com/MediaCommon/SVGs/FontAwesome/clone.blue.svg" style="box-sizing:border-box;position:relative;overflow:hidden;vertical-align:middle !important;width:auto;max-width:16px;height:16px;" /><span class="Text">Copy</span></a></div><div class="TableTitleButton"><a href="#" onclick="bfs.util.codeEditorSelectAll('code019d6b69cb6c73d6b65007ceb98ee790Js'); return false;"><img src="https://www.displayfusion.com/MediaCommon/SVGs/FontAwesome/square-check.blue.svg" style="box-sizing:border-box;position:relative;overflow:hidden;vertical-align:middle !important;width:auto;max-width:16px;height:16px;" /><span class="Text">Select All</span></a></div></div></h2><div class="TableTitleContent table-responsive"><div class="AceEditorWrapper" style="border-top:solid 1px var(--color-default-border);padding:0"><pre id="code019d6b69cb6c73d6b65007ceb98ee790Js" contenteditable="true" spellcheck="true" class="skiptranslate" style="width:100%; min-height:75px;">using System;

public static class DisplayFusionFunction
{
    public static void Run(IntPtr windowHandle)
    {
        var count = 0;
        var monIDs = BFS.Monitor.GetMonitorIDs();
        foreach (var mon in monIDs)
            count ++;
        
        if (count.Equals(1))
            BFS.DisplayFusion.LoadMonitorProfile("Surface Display Only");
        else if (count.Equals(2))
            BFS.DisplayFusion.LoadMonitorProfile("Surface Display Disabled - Single Monitor");
        else if (count.Equals(3))
            BFS.DisplayFusion.LoadMonitorProfile("Surface Display Disabled");
    }
}</pre><textarea id="code019d6b69cb6c73d6b65007ceb98ee790" name="code019d6b69cb6c73d6b65007ceb98ee790" style="position:absolute; top:0; left:-999999px; width:1px; height:1px;"></textarea></div>
</div></div></div>
</div>
]]></content:encoded>
</item>
<item>
<title>RE: Loading monitor profiles when docking / undocking Microsoft Surface</title>
<link>https://www.displayfusion.com/Discussions/View/loading-monitor-profiles-when-docking-undocking-microsoft-surface/?ID=81c3c362-4e73-463a-9dea-12ab2797ec5f#7</link>
<pubDate>Mon, 24 Jul 2017 11:25:23 GMT</pubDate>
<dc:creator>Binary Fortress Software</dc:creator>
<guid isPermaLink="false">https://www.displayfusion.com/Discussions/View/loading-monitor-profiles-when-docking-undocking-microsoft-surface/?ID=81c3c362-4e73-463a-9dea-12ab2797ec5f#7</guid>
<category>DisplayFusion</category>
<description><![CDATA[Thanks Keith, but those definitions are for DF version 9. We are still on 8.1.2.
Are there any definitions I can utilise in 8.1.2 that could do the same task?
The GetMonitorIDs definition would be most suitable I reckon.
Is there a property similar to 'NAME' I could use so a script could be wr...]]></description>
<content:encoded><![CDATA[<div class="CTDiscussions">
Thanks Keith, but those definitions are for DF version 9. We are still on 8.1.2.<br/>
Are there any definitions I can utilise in 8.1.2 that could do the same task?<br/>
<br/>
The GetMonitorIDs definition would be most suitable I reckon.<br/>
Is there a property similar to 'NAME' I could use so a script could be written like the one below?<br/>
<br/>
public static class DisplayFusionFunction<br/>
{<br/>
public static void Run(IntPtr windowHandle)<br/>
{<br/>
if (BFS.Monitor.GetMonitorIDs().NAME = 1)<br/>
            {<br/>
                BFS.DisplayFusion.LoadMonitorProfile("Surface Display Only");<br/>
            }<br/>
        else if (BFS.Monitor.GetMonitorIDs().NAME = 1 & 2)<br/>
            {<br/>
                BFS.DisplayFusion.LoadMonitorProfile("Surface Display Disabled - Single Monitor");<br/>
            }   <br/>
        else if (BFS.Monitor.GetMonitorIDs().NAME = 1 , 2 & 3)<br/>
            {<br/>
                BFS.DisplayFusion.LoadMonitorProfile("Surface Display Disabled");     <br/>
<br/>
}<br/>
}<br/>
<br/>
Thanks
</div>
]]></content:encoded>
</item>
<item>
<title>RE: Loading monitor profiles when docking / undocking Microsoft Surface</title>
<link>https://www.displayfusion.com/Discussions/View/loading-monitor-profiles-when-docking-undocking-microsoft-surface/?ID=81c3c362-4e73-463a-9dea-12ab2797ec5f#6</link>
<pubDate>Fri, 21 Jul 2017 18:23:17 GMT</pubDate>
<dc:creator>Binary Fortress Software</dc:creator>
<guid isPermaLink="false">https://www.displayfusion.com/Discussions/View/loading-monitor-profiles-when-docking-undocking-microsoft-surface/?ID=81c3c362-4e73-463a-9dea-12ab2797ec5f#6</guid>
<category>DisplayFusion</category>
<description><![CDATA[Sure thing! I've attached a sample Scripted Function for you.]]></description>
<content:encoded><![CDATA[<div class="CTDiscussions">
Sure thing! I've attached a sample Scripted Function for you.
</div>
]]></content:encoded>
</item>
<item>
<title>RE: Loading monitor profiles when docking / undocking Microsoft Surface</title>
<link>https://www.displayfusion.com/Discussions/View/loading-monitor-profiles-when-docking-undocking-microsoft-surface/?ID=81c3c362-4e73-463a-9dea-12ab2797ec5f#5</link>
<pubDate>Fri, 21 Jul 2017 08:30:59 GMT</pubDate>
<dc:creator>Binary Fortress Software</dc:creator>
<guid isPermaLink="false">https://www.displayfusion.com/Discussions/View/loading-monitor-profiles-when-docking-undocking-microsoft-surface/?ID=81c3c362-4e73-463a-9dea-12ab2797ec5f#5</guid>
<category>DisplayFusion</category>
<description><![CDATA[Thanks
I've been looking through the functions and perhaps BFS.Monitor.GetMonitorIDs could help here. If monitor 1 is the only attached monitor then a profile for built in display is loaded. If 1 & 2 are attached then single monitor profile is loaded and if 1, 2 & 3 are attached then the profile...]]></description>
<content:encoded><![CDATA[<div class="CTDiscussions">
Thanks<br/>
<br/>
I've been looking through the functions and perhaps BFS.Monitor.GetMonitorIDs could help here. If monitor 1 is the only attached monitor then a profile for built in display is loaded. If 1 & 2 are attached then single monitor profile is loaded and if 1, 2 & 3 are attached then the profile for 2 external monitors is loaded.<br/>
<br/>
Is this something you could help rustle up?<br/>
<br/>
Thanks
</div>
]]></content:encoded>
</item>
<item>
<title>RE: Loading monitor profiles when docking / undocking Microsoft Surface</title>
<link>https://www.displayfusion.com/Discussions/View/loading-monitor-profiles-when-docking-undocking-microsoft-surface/?ID=81c3c362-4e73-463a-9dea-12ab2797ec5f#4</link>
<pubDate>Thu, 20 Jul 2017 13:44:05 GMT</pubDate>
<dc:creator>Binary Fortress Software</dc:creator>
<guid isPermaLink="false">https://www.displayfusion.com/Discussions/View/loading-monitor-profiles-when-docking-undocking-microsoft-surface/?ID=81c3c362-4e73-463a-9dea-12ab2797ec5f#4</guid>
<category>DisplayFusion</category>
<description><![CDATA[Oh yeah, no worries. I can write up a Scripted Function. The issue might be with the Triggers though. The only Trigger Events that might work here would be "DisplayFusion Starts" or "Desktop Unlocked." So we can have the script fire when DisplayFusion Starts or the user unlocks their desktop, and...]]></description>
<content:encoded><![CDATA[<div class="CTDiscussions">
Oh yeah, no worries. I can write up a Scripted Function. The issue might be with the Triggers though. The only Trigger Events that might work here would be "DisplayFusion Starts" or "Desktop Unlocked." So we can have the script fire when DisplayFusion Starts or the user unlocks their desktop, and it will check how many monitors are connected and apply the profile if necessary. Does that sound like it would work?
</div>
]]></content:encoded>
</item>
<item>
<title>RE: Loading monitor profiles when docking / undocking Microsoft Surface</title>
<link>https://www.displayfusion.com/Discussions/View/loading-monitor-profiles-when-docking-undocking-microsoft-surface/?ID=81c3c362-4e73-463a-9dea-12ab2797ec5f#3</link>
<pubDate>Thu, 20 Jul 2017 10:03:51 GMT</pubDate>
<dc:creator>Binary Fortress Software</dc:creator>
<guid isPermaLink="false">https://www.displayfusion.com/Discussions/View/loading-monitor-profiles-when-docking-undocking-microsoft-surface/?ID=81c3c362-4e73-463a-9dea-12ab2797ec5f#3</guid>
<category>DisplayFusion</category>
<description><![CDATA[I wouldn't know where to start with creating a VB script to detect if external monitors are connected or not.
Users could have their devices powered on or off when hotdesking but profiles still don't automatically load.]]></description>
<content:encoded><![CDATA[<div class="CTDiscussions">
I wouldn't know where to start with creating a VB script to detect if external monitors are connected or not.<br/>
Users could have their devices powered on or off when hotdesking but profiles still don't automatically load.
</div>
]]></content:encoded>
</item>
<item>
<title>RE: Loading monitor profiles when docking / undocking Microsoft Surface</title>
<link>https://www.displayfusion.com/Discussions/View/loading-monitor-profiles-when-docking-undocking-microsoft-surface/?ID=81c3c362-4e73-463a-9dea-12ab2797ec5f#2</link>
<pubDate>Wed, 19 Jul 2017 14:36:58 GMT</pubDate>
<dc:creator>Binary Fortress Software</dc:creator>
<guid isPermaLink="false">https://www.displayfusion.com/Discussions/View/loading-monitor-profiles-when-docking-undocking-microsoft-surface/?ID=81c3c362-4e73-463a-9dea-12ab2797ec5f#2</guid>
<category>DisplayFusion</category>
<description><![CDATA[You might be able to load the profile automatically with a combination of a Scripted Function and a Trigger rule. Do they lock, sleep, or shutdown the Surface before switching to another hotdesk, or is the Surface running and logged in when they dock at the hotdesk?]]></description>
<content:encoded><![CDATA[<div class="CTDiscussions">
You might be able to load the profile automatically with a combination of a Scripted Function and a Trigger rule. Do they lock, sleep, or shutdown the Surface before switching to another hotdesk, or is the Surface running and logged in when they dock at the hotdesk?
</div>
]]></content:encoded>
</item>
<item>
<title>Loading monitor profiles when docking / undocking Microsoft Surface</title>
<link>https://www.displayfusion.com/Discussions/View/loading-monitor-profiles-when-docking-undocking-microsoft-surface/?ID=81c3c362-4e73-463a-9dea-12ab2797ec5f</link>
<pubDate>Wed, 19 Jul 2017 09:47:11 GMT</pubDate>
<dc:creator>Binary Fortress Software</dc:creator>
<guid isPermaLink="false">https://www.displayfusion.com/Discussions/View/loading-monitor-profiles-when-docking-undocking-microsoft-surface/?ID=81c3c362-4e73-463a-9dea-12ab2797ec5f</guid>
<category>DisplayFusion</category>
<description><![CDATA[We have over 200 MS Surface devices with each user able to hotdesk and dock their device at any available desk. I have created 3 monitor profiles to suit our environment. These monitor profiles are applied to each device by a group policy which imports registry settings exported from a reference ...]]></description>
<content:encoded><![CDATA[<div class="CTDiscussions">
We have over 200 MS Surface devices with each user able to hotdesk and dock their device at any available desk. I have created 3 monitor profiles to suit our environment. These monitor profiles are applied to each device by a group policy which imports registry settings exported from a reference device.<br/>
I have refrained from applying a default profile on start up as if the monitor configuration does not match the profile, an error occurs. I believe that this error can be suppressed in the latest beta release.<br/>
The issue I am having, is when a user manually loads a profile, it will only recognise the profile if the user is using the Surface Dock the profile was loaded on. If they dock the Surface on another hotdesk, the profile is forgotten and they need to load the profile again. I cannot understand why this should be the case as the hardware (Surface Dock, monitors) is identical on each desk.<br/>
Are there any triggers I can use that can load a profile when a Surface is docked or undocked as this would sort our issues until the default profile error suppression is released to production,<br/>
<br/>
Thanks
</div>
]]></content:encoded>
</item>
</channel>
</rss>