mIRC Homepage
Posted By: beer DDE help - 30/08/20 06:37 PM
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.
Posted By: KindOne Re: DDE help - 30/08/20 08:42 PM
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.
Posted By: beer Re: DDE help - 30/08/20 11:50 PM
I renamed them through the options -> other -> dde menu.
Posted By: KindOne Re: DDE help - 31/08/20 06:12 PM
Renaming it via the options->other->dde works for me.
Posted By: Khaled Re: DDE help - 01/09/20 08:27 AM
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.
© mIRC Discussion Forums