mIRC Homepage

vars and custom windows..

Posted By: clutz1572

vars and custom windows.. - 09/12/08 02:36 PM

hey guys...

i have a question about more or less dupe checking contents in a custom window...

i'm not sure how to go about this.. i have a series of vars that get added/stored to a hidden custom window, in this manor:

they get tokenized $1 $2 $3 $4
checked if the vars are true :
if (%blah) && (%blah2) && (%blah3) && (%blah4) return

then gets added through alias that also does some other stuff:

custom alias $ntfy:
%var %tab = $chr(9), %c = @_my_window

aline %c $1 %tab $+($2,) %tab $3 %tab $4

this this info above is what goes into the hidden custom window .. then all else continues on...

what i'd like to do here is to make a check to see if there are dupe lines being added.. if so halt it, if not add it.. i'd like to be able to check vars blah3 and blah4 against items $3 and $4 that have been previously added to the hidden custom window...

would someone be able to point me in the right direction at least, if not show how to do this.. ??

i hope i'm not being to confusing.... and thanks in advance laugh

Posted By: qwerty

Re: vars and custom windows.. - 09/12/08 02:40 PM

Use /aline -n to add lines.
Posted By: clutz1572

Re: vars and custom windows.. - 09/12/08 03:05 PM


yeah huh..... lol thanks qwerty.. i feel sheepish now, since i didn't look to see if aline had a switch for that.. I should've known.... oh well.. laugh
Posted By: RoCk

Re: vars and custom windows.. - 09/12/08 03:13 PM

To check if a new line was actually added or not you could...

custom alias $ntfy:
var %tab = $chr(9), %c = @_my_window,%l = $line(%c,0)
aline -n %c $1 %tab $+($2,) %tab $3 %tab $4
if ($line(%c,0) > %l) echo -a A new line was added.
else echo -a Line already exists.

© 2020 mIRC Discussion Forums