mIRC Home    About    Download    Register    News    Help

Print Thread
DDE help #267644 30/08/20 06:37 PM
Joined: Jul 2007
Posts: 63
B
beer Offline OP
Babel fish
OP Offline
Babel fish
B
Joined: Jul 2007
Posts: 63
Hi. I have a mirc instance running a DDE server as mirc1 and the following alias defined in a remote script:

alias testz {
if ($1 = yes) { return 1 }
else { return 0 }
}

I have a second mirc instance running also with a DDE server as mirc2 and the following text trigger:

on *:text:!ddetest:#:{
var %result = $dde(mirc1,evaluate,$testz(yes))
msg # result: %result
}

Because I can't trigger !ddetest on the same mirc, I do it from the first mirc. I expected to see "result: 1" but instead just see "result:".. I also tried changing the evaluate to execute but got the same response. Any idea what I'm doing wrong?

Thanks in advance!

EDIT:
It works as expect. The problem was I changed the DDE server names after the two mirc's were already running. Apparently changing the server name doesn't automatically restart the server so I had to "/ddeserver off" then "/ddeserver on" for it to work.

Last edited by beer; 30/08/20 07:44 PM. Reason: SOLVED
Re: DDE help [Re: beer] #267645 30/08/20 08:42 PM
Joined: Feb 2011
Posts: 364
K
KindOne Offline
Pan-dimensional mouse
Offline
Pan-dimensional mouse
K
Joined: Feb 2011
Posts: 364
How were you renaming them? Manually renaming and using scripts renaming them works for me.

mIRC1:
Code
alias dde_test {
  var %x $rand(1,2000)
  ddeserver on $version
  ddeserver on testing
  ddeserver on %x
  dde -e foobar command /ddeserver on mIRC_2
  dde -e mIRC_2 command /ddeserver on mIRC_3
  dde -e mIRC_3 command /dde -e %x command /echo -ag Works for me. 
  dde -e mIRC_3 command /ddeserver on foobar
  dde -e foobar command /dde -e %x command /echo -ag mIRC2 renamed into foobar.
}


mIRC2:
Code
on *:start:{ ddeserver on foobar } 



Results in mIRC1:

Code
* DDE Server is on (7.63)
* DDE Server is on (testing)
* DDE Server is on (191)
Works for me.
mIRC2 renamed into foobar.


irc.swiftirc.net #msl (mIRC Scripting Language)
Re: DDE help [Re: KindOne] #267646 30/08/20 11:50 PM
Joined: Jul 2007
Posts: 63
B
beer Offline OP
Babel fish
OP Offline
Babel fish
B
Joined: Jul 2007
Posts: 63
I renamed them through the options -> other -> dde menu.

Re: DDE help [Re: beer] #267654 31/08/20 06:12 PM
Joined: Feb 2011
Posts: 364
K
KindOne Offline
Pan-dimensional mouse
Offline
Pan-dimensional mouse
K
Joined: Feb 2011
Posts: 364
Renaming it via the options->other->dde works for me.


irc.swiftirc.net #msl (mIRC Scripting Language)
Re: DDE help [Re: KindOne] #267661 01/09/20 08:27 AM
Joined: Dec 2002
Posts: 4,795
Khaled Offline
Hoopy frood
Offline
Hoopy frood
Joined: Dec 2002
Posts: 4,795
Quote
Renaming it via the options->other->dde works for me.

It looks like there is an issue where the DDE server settings are not always applied when they are changed in the DDE Options dialog. This has been fixed for the next version.