public Command(IDDESender sender, DDEAction action, string commandText = null, string valueText = null) { Sender = sender; Action = action; CommandText = commandText; ValueText = valueText; }
public void Close(IDDESender sender) { Connection conn; if (m_connections.TryGetValue(sender, out conn)) { using (var ds = new DDESender(this, sender)) { m_commands.Enqueue(new Command(ds, DDEAction.Close)); //DDECompletitionManager.Instance.Post(() => ProcessCommand(new Command(ds, DDEAction.Close))); WaitComplete(); //m_complete.WaitOne(Timeout.Infinite); } } }
void InternalClose(object form) { Connection conn; if (m_connections.TryGetValue(form, out conn)) { DDEML.DdeDisconnect(conn.Conv); m_connections.TryRemove(form, out conn); IDDESender sender = form as IDDESender; if (sender != null) { sender.OnComplete(DDEAction.Close, conn.Name, null); } } }
public void ExecuteMacroAsync(IDDESender sender, string strText) { m_commands.Enqueue(new Command(sender, DDEAction.Send, strText)); //DDECompletitionManager.Instance.Post(() => ProcessCommand(new Command(sender, DDEAction.Send, strText))); }
public void PokeDataAsync(IDDESender sender, string itemName, string strData) { m_commands.Enqueue(new Command(sender, DDEAction.Send, itemName, strData)); //DDECompletitionManager.Instance.Post(() => ProcessCommand(new Command(sender, DDEAction.Send, itemName, strData))); }