using System;
using System.Linq;
using System.Collections.Generic;
public static class DisplayFusionFunction
{
public static void Run(IntPtr windowHandle)
{
Dictionary<string, string> keyValuePairs = new Dictionary<string, string>()
{
{
"Phrase #1", "This is Display Fusion 'typing' your Phrase #1"
},
{
"Phrase #2", "This is Display Fusion 'typing' your Phrase #2"
},
{
"Phrase #3", "This is Display Fusion 'typing' your Phrase #3"
},
{
"--------------", ""
},
{
"Phrase #4", "This is Display Fusion 'typing' your Phrase #4"
}
};
string[] aryOptions = keyValuePairs.Keys.ToArray();
string input = BFS.Dialog.GetUserInputList("Auto-Fill", aryOptions);
// Retrieve a value using a key
string value;
if (keyValuePairs.TryGetValue(input, out value))
{
BFS.Input.SendText(value);
}
else
{
BFS.Dialog.ShowMessageError($"{input} key was not found in the dictionary.");
}
}
}