Robin Lund
5 discussion posts
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.
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.
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.
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,
Thanks
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?
Robin Lund
5 discussion posts
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.
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?
Robin Lund
5 discussion posts
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 for 2 external monitors is loaded.
Is this something you could help rustle up?
Thanks
Sure thing! I've attached a sample Scripted Function for you.
Robin Lund
5 discussion posts
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 written like the one below?
public static class DisplayFusionFunction
{
public static void Run(IntPtr windowHandle)
{
if (BFS.Monitor.GetMonitorIDs().NAME = 1)
{
BFS.DisplayFusion.LoadMonitorProfile("Surface Display Only");
}
else if (BFS.Monitor.GetMonitorIDs().NAME = 1 & 2)
{
BFS.DisplayFusion.LoadMonitorProfile("Surface Display Disabled - Single Monitor");
}
else if (BFS.Monitor.GetMonitorIDs().NAME = 1 , 2 & 3)
{
BFS.DisplayFusion.LoadMonitorProfile("Surface Display Disabled");
}
}
Thanks
Robin Lund
5 discussion posts
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 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.
Thanks
• Attachment [protected]: DisplayFusion Cloned Screens.rtf [6,302,074 bytes]
Jul 25, 2017 (modified Jul 25, 2017)
•
#9