Processing Ajax...

Title

Message

Confirm

Confirm

Confirm

Confirm

Are you sure you want to delete this item?

Confirm

Are you sure you want to delete this item?

Confirm

Are you sure?

User Image
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
Jul 19, 2017  • #1
Keith Lammers (BFS)'s profile on WallpaperFusion.com
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?
Jul 19, 2017  • #2
User Image
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.
Jul 20, 2017  • #3
Keith Lammers (BFS)'s profile on WallpaperFusion.com
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?
Jul 20, 2017  • #4
User Image
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
Jul 21, 2017  • #5
Keith Lammers (BFS)'s profile on WallpaperFusion.com
Sure thing! I've attached a sample Scripted Function for you.
• Attachment: MonitorProfileLoadingScript.txt [607 bytes]
Jul 21, 2017  • #6
User Image
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
Jul 24, 2017  • #7
PabloMartinez's profile on WallpaperFusion.com
For DF 8.1.2 you can use something like that.

Code

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");
    }
}
Jul 24, 2017 (modified Jul 26, 2017)  • #8
User Image
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
Subscribe to this discussion topic using RSS
Was this helpful?  Login to Vote(-)  Login to Vote(-)