Esempio n. 1
0
 public Command(IDDESender sender, DDEAction action, string commandText = null, string valueText = null)
 {
     Sender      = sender;
     Action      = action;
     CommandText = commandText;
     ValueText   = valueText;
 }
Esempio n. 2
0
        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);
                }
            }
        }
Esempio n. 3
0
        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);
                }
            }
        }
Esempio n. 4
0
 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)));
 }
Esempio n. 5
0
 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)));
 }