mIRC Home    About    Download    Register    News    Help

Print Thread
Identifier for the log file? #22033 03/05/03 06:15 AM
Joined: Jan 2003
Posts: 66
M
maezr Offline OP
Babel fish
OP Offline
Babel fish
M
Joined: Jan 2003
Posts: 66
Of a particular channel?

Any idea how I could make something to do that?

Re: Identifier for the log file? #22034 03/05/03 06:20 AM
Joined: Dec 2002
Posts: 699
N
Nimue Offline
Fjord artisan
Offline
Fjord artisan
N
Joined: Dec 2002
Posts: 699
$window(#channel).logfile

Re: Identifier for the log file? #22035 13/05/03 09:12 PM
Joined: Jan 2003
Posts: 66
M
maezr Offline OP
Babel fish
OP Offline
Babel fish
M
Joined: Jan 2003
Posts: 66
Sometimes the log names are more complex than that, though. ie, with dates, etc.

So you're saying there's no actual identifier?

Re: Identifier for the log file? #22036 13/05/03 09:30 PM
Joined: Jan 2003
Posts: 66
M
maezr Offline OP
Babel fish
OP Offline
Babel fish
M
Joined: Jan 2003
Posts: 66
Nevermind, I got that much.

Now, though, how would I do the same thing for a given $nick?

Re: Identifier for the log file? #22037 13/05/03 09:38 PM
Joined: Dec 2002
Posts: 3,138
C
Collective Offline
Hoopy frood
Offline
Hoopy frood
C
Joined: Dec 2002
Posts: 3,138
$window([color:green]nickname).logfile[/color]
If you want to get the logfile for the active window (either channel or query) you can use this:
$window($active).logfile

That needs the window to be open, though...

Re: Identifier for the log file? #22038 13/05/03 10:00 PM
Joined: Jan 2003
Posts: 66
M
maezr Offline OP
Babel fish
OP Offline
Babel fish
M
Joined: Jan 2003
Posts: 66
Thanks, but I'm trying to use this in a channel popup, not a query.

How would I do that?

Re: Identifier for the log file? #22039 13/05/03 10:03 PM
Joined: Jan 2003
Posts: 66
M
maezr Offline OP
Babel fish
OP Offline
Babel fish
M
Joined: Jan 2003
Posts: 66
Actually, that doesn't seem to work for either for me...

I get insufficient parameters.

Re: Identifier for the log file? #22040 13/05/03 10:07 PM
Joined: Dec 2002
Posts: 3,138
C
Collective Offline
Hoopy frood
Offline
Hoopy frood
C
Joined: Dec 2002
Posts: 3,138
It won't work unless the a query window to the nick is open..I don't think there is a way round that.

Edit:
Maybe something like this would work?
query -n $nick | echo -s $window($nick).logfile | close -m $nick

Re: Identifier for the log file? #22041 13/05/03 10:11 PM
Joined: Jan 2003
Posts: 66
M
maezr Offline OP
Babel fish
OP Offline
Babel fish
M
Joined: Jan 2003
Posts: 66
Okay, well, what should I be using for an identifier for the current PM nick?

$nick wouldn't work, obviously.

Thanks for your help.

Re: Identifier for the log file? #22042 13/05/03 10:13 PM
Joined: Dec 2002
Posts: 3,138
C
Collective Offline
Hoopy frood
Offline
Hoopy frood
C
Joined: Dec 2002
Posts: 3,138
Read the edit of the last post I made, maybe that will help you figure something out. When you say the current PM nick, do you mean the logfile for the query you currently have opened? $window($active).logfile will do that.

Re: Identifier for the log file? #22043 13/05/03 10:15 PM
Joined: Jan 2003
Posts: 66
M
maezr Offline OP
Babel fish
OP Offline
Babel fish
M
Joined: Jan 2003
Posts: 66
menu query {
-
Open log {
run $window($nick).logfile
}
-
}

$nick doesn't work in that, that's what I'm trying to sort out. :\

Thanks again

Re: Identifier for the log file? #22044 13/05/03 10:16 PM
Joined: Dec 2002
Posts: 3,138
C
Collective Offline
Hoopy frood
Offline
Hoopy frood
C
Joined: Dec 2002
Posts: 3,138
menu query {
-
Open log {
run $window($active).logfile
}
-
}

Re: Identifier for the log file? #22045 13/05/03 10:38 PM
Joined: Dec 2002
Posts: 699
N
Nimue Offline
Fjord artisan
Offline
Fjord artisan
N
Joined: Dec 2002
Posts: 699
There is also $mklogfn()
$logdir $+ $mklogfn(<nick|chan|word|number|$$1|$active|etc>)
$logdir $+ $mklogfn($1)