Re: TIdIRC OnNames IsOp

Giganews Newsgroups
Subject: Re: TIdIRC OnNames IsOp
Posted by:  Remy Lebeau (Indy Team) (
Date: Tue, 25 Jul 2006

"Danila Vershinin" <profyprepATyandexDOTru> wrote in message

> IsOp would never return true since in this piece of code it deals
> with nicknames without status tokens. For example, I have ops
> on the channel: @Danilka. But TIdIRCUser's Nick would
> containg Danilka only (without @ required for that function to
> work correctly in my code)

Then the IRC server is likely not sending the op status to begin with.
TIdIRC stores the Nicknames exactly as the server provides them.

> So my question is, do I check whether a user has ops
> on a particular channel (or any channel...) ?

You can't, if the server is not already including that information to begin

> when I use Delphi 7 + Indy 10 OnNickNameListReceived is never
> triggered when I join a channel.

That event is triggered in response to the same command that triggers the
OnNames event in Indy 9.  If it is not being triggered, then the server is
likely not sending it to begin with.

> Maybe it's the way I use it...
> Just for a test I did this:

Do not do that in the OnCreate event.  Use a button OnClick event or
anything else that is triggered after the form is up and running.  OnCreate
is too soon.  The DFM may not have been fully streamed at that time, so your
event handlers may not have been assigned yet.

> doesn't Indy 10 TIdIRC support multiple channels? I couldn't
> find anything related to TIdIRCChannel as it is back in Indy 9. ?

Indy 10 does not keep track of any channels at all anymore.  That is your
own responsibility to handle now.



In response to

TIdIRC OnNames IsOp posted by Danila Vershinin on Tue, 25 Jul 2006