mIRC Home    About    Download    Register    News    Help

Print Thread
Joined: Mar 2003
Posts: 3
P
Paule Offline OP
Self-satisified door
OP Offline
Self-satisified door
P
Joined: Mar 2003
Posts: 3
Hello everybody smile

I did search the helpfiles and the forums but didn't find an answer. Hopefully I'm not no. 3474 who asked this question blush

Here they are:

1) Is there an equivalent to eg. delphi's "assigned" function?
Means: Is there a possibility to figure out whether some special alias exists or not.

Example: Imagine there exists an alias called "test"
if ( $assigned(test) != $null ) {
/test someparameters
}
else {
/echo -s no valid alias
}

-----------------------------------------------------------------

2) Is there a possibillity to give the processcontrol back to mIRC (or the system) while within a script? (equivalent to the delphi's Application.ProcessMessages)

Example: this will cause an infinite loop an therefore "block" any other process, including mirc.
while ($true) {
/echo -s hello
}

It would be nice to give mirc and the system some processtime within the loop. Example:
while ($true) {
/echo -s hello
/processmessages
}

Hopefully I could formulate my questions understandable. Thx in advance for any answer smile

Paule

Joined: Dec 2002
Posts: 3,138
C
Hoopy frood
Offline
Hoopy frood
C
Joined: Dec 2002
Posts: 3,138
1. I'm not familiar with Delphi so excuse me if I get this wrong. $isalias(aliasname) returns $true if an alias exists, $false if it doesn't.

2. I have no idea (there is not a command to do this, but there might be a way to produce the same effect). There might be a way using the /sleep script, but I don't use it so hopefully someone else will answer..you could use a /timer (but it would be a few hundred times slower than using a while loop). Something similar to this was posted here which might help.

Joined: Mar 2003
Posts: 3
P
Paule Offline OP
Self-satisified door
OP Offline
Self-satisified door
P
Joined: Mar 2003
Posts: 3
Hello Collective

1. Thank you very much, that was exactly I was looking for smile

2. Well... yes, that seems to be the same problem I have.
But to be honest the solution is not very elegant. That would be some kind of goto-spagetti-programming with timers grin

Could it be that this is really some missing feature in mIRC?

Regards
Paule

Joined: Dec 2002
Posts: 3,138
C
Hoopy frood
Offline
Hoopy frood
C
Joined: Dec 2002
Posts: 3,138
Quote:
Could it be that this is really some missing feature in mIRC?

Yes, you can join the campaign for it to be added in the link I gave (I edited it in after, sorry if you didn't see it).


Link Copied to Clipboard