{ "name": "Prompt for Monitor Profile", "language": 0, "code": "using System;\r\nusing System.Drawing;\r\nusing System.Collections.Generic;\r\n\r\npublic static class DisplayFusionFunction\r\n{\r\n\tpublic static void Run(IntPtr windowHandle)\r\n\t{\r\n\t\t// Get the list of all functions\r\n\t\tstring[] allFunctions = BFS.DisplayFusion.GetFunctions();\r\n\t\t\r\n\t\t// Build a new list with only the Window Position Profile functions\r\n\t\tList wppFunctions = new List();\r\n\t\t\r\n\t\tforeach (string function in allFunctions)\r\n\t\t{\r\n if (function.Contains(\"Load Monitor Profile\"))\r\n {\r\n string wppName = function.Replace(\"Load Monitor Profile: \", \"\");\r\n wppFunctions.Add(wppName);\r\n }\r\n\t\t}\r\n\t\t\r\n\t\t// Show the list so the user can choose one\r\n\t\tstring selectedProfile = \"Load Monitor Profile: \" + BFS.Dialog.GetUserInputListViewWithFilter(\"Choose the Monitor Profile to load\", wppFunctions.ToArray());\r\n\t\t//BFS.Dialog.ShowMessageInfo(selectedProfile);\r\n\t\t\r\n\t\t// Load the selected profile\r\n\t\tBFS.DisplayFusion.RunFunction(selectedProfile);\r\n\t}\r\n}", "description": "This script will show a list of all of your Window Position Profiles, and allow you to select one to load.", "references": "System.Core.dll|System.Data.dll|System.dll|System.Drawing.dll|System.Management.dll|System.Web.dll|System.Windows.Forms.dll|System.Xml.dll" }