mIRC Home    About    Download    Register    News    Help

Print Thread
How to (Re-) Open a channel window? #173676
27/03/07 03:35 PM
27/03/07 03:35 PM
Joined: Mar 2007
Posts: 9
L
Lastwebpage Offline OP
Nutrimatic drinks dispenser
Lastwebpage  Offline OP
Nutrimatic drinks dispenser
L

Joined: Mar 2007
Posts: 9
Hello,
I have re-wrote/motify an existing script with balloon popups on the desktop if someone write something.

It works good except one thing. When the ballon appaer it display the channelname, the user and the text, but how:
-How can I display the groupname? $server show me the the full URL to the server, but I want the groupname.
-I use showmirc -s to show the mIRC window if it was minimized/in tray, but how can I select the channel for the message that I not must scroll through all the channels to find the right one, for example:
User ABC Wrote in #XYZ on SERVER:
Blah blah
Now I want that #XYZ is selected and opens when I click on the balloon.

Peter

Re: How to (Re-) Open a channel window? [Re: Lastwebpage] #173677
27/03/07 03:39 PM
27/03/07 03:39 PM
Joined: Dec 2002
Posts: 2,010
R
RoCk Offline
Hoopy frood
RoCk  Offline
Hoopy frood
R

Joined: Dec 2002
Posts: 2,010
Quote:
How can I display the groupname?

$network ?

Quote:
Now I want that #XYZ is selected and opens when I click on the balloon.


/window -a #XYZ

Last edited by RoCk; 27/03/07 03:43 PM.
Re: How to (Re-) Open a channel window? [Re: RoCk] #173686
27/03/07 06:42 PM
27/03/07 06:42 PM
Joined: Mar 2007
Posts: 9
L
Lastwebpage Offline OP
Nutrimatic drinks dispenser
Lastwebpage  Offline OP
Nutrimatic drinks dispenser
L

Joined: Mar 2007
Posts: 9
thanks for the answer,
but the second answer not work correct, because unfortunately I have some channels with the same name on different servers.

Peter

Re: How to (Re-) Open a channel window? [Re: Lastwebpage] #173687
27/03/07 06:44 PM
27/03/07 06:44 PM
Joined: Mar 2003
Posts: 612
Aberdeen, Scotland
B
billythekid Offline
Fjord artisan
billythekid  Offline
Fjord artisan
B

Joined: Mar 2003
Posts: 612
Aberdeen, Scotland
/join #channel should work. I use short aliases to quickly change between active channels all using /join, even when already IN the channel.

Last edited by billythekid; 27/03/07 06:45 PM.

billythekid
Re: How to (Re-) Open a channel window? [Re: billythekid] #173697
27/03/07 09:23 PM
27/03/07 09:23 PM
Joined: Mar 2007
Posts: 9
L
Lastwebpage Offline OP
Nutrimatic drinks dispenser
Lastwebpage  Offline OP
Nutrimatic drinks dispenser
L

Joined: Mar 2007
Posts: 9
hmmmh, I guess my question was not clearly enough...
1) I am in ~20 channels online, some of them have the same name, #help for example, and mIRC is minimized in the tray
2) someone write something on Server ABC in Channel XYZ
3) the script show me with the picture window function a window with "User 123 wrote on ABC in channel XYZ ...." on the desktop
4) I click on this picture window on the desktop
5) I open mIRC and I must search in the treebar/switchbar in which channel the user have spoke something and click on it to open the channel.

It would be nice if I could do the same thing like this search in the tree and open/select the channel within the script.

At the moment I have the following code (thanks Rock)
Code:
menu @DesktopPopup {
  sclick { 
    showmirc $iif($appstate == minimized,-r,-s)
    window -a %DesktopPopup.LastChannel
  }
  rclick { DesktopPopup.doclose $iif($mouse.key & 4,-s) }
  $DesktoPopup.doclose
}
;DesktopPopup.LastChannel stores the channel which "produce" the DestopPopup

But this not work correctly, it works only if the same group than the message was selected before I minmized mIRC, if another group was selected, mIRC opens, but I must open and select the correct channel per hand.

Last edited by Lastwebpage; 27/03/07 09:27 PM.
Re: How to (Re-) Open a channel window? [Re: Lastwebpage] #173700
27/03/07 09:58 PM
27/03/07 09:58 PM
Joined: Dec 2002
Posts: 2,010
R
RoCk Offline
Hoopy frood
RoCk  Offline
Hoopy frood
R

Joined: Dec 2002
Posts: 2,010
Set a variable for the CID like you did for the channel...

you set %DesktopPopup.LastChannel to $chan or #
so also set %DesktopPopup.LastCID to $cid

then use the /scid command in your script with the new variable %DesktopPopup.LastCID

Code:
menu @DesktopPopup {
  sclick { 
    showmirc $iif($appstate == minimized,-r,-s)
    scid %DesktopPopup.LastCID window -a %DesktopPopup.LastChannel
  }
  rclick { DesktopPopup.doclose $iif($mouse.key & 4,-s) }
  $DesktoPopup.doclose
}
;DesktopPopup.LastChannel stores the channel which "produce" the DestopPopup
;DesktopPopup.LastCID stores the connection ID (CID) which "produce" the DesktopPopup

Re: How to (Re-) Open a channel window? [Re: RoCk] #173702
27/03/07 10:38 PM
27/03/07 10:38 PM
Joined: Mar 2007
Posts: 9
L
Lastwebpage Offline OP
Nutrimatic drinks dispenser
Lastwebpage  Offline OP
Nutrimatic drinks dispenser
L

Joined: Mar 2007
Posts: 9
That was the solution,
many thanks.

Peter