mIRC Home    About    Download    Register    News    Help

Print Thread
#195500 26/02/08 03:55 AM
Joined: Feb 2008
Posts: 1
M
MiNdy Offline OP
Mostly harmless
OP Offline
Mostly harmless
M
Joined: Feb 2008
Posts: 1
Hi. Is it possible to create a script that would toggle highlight on/off with just one command without having to go to options and enable/disable it there? Doesn't sound too easy to a beginner like me but maybe someone could try to help.
My mIRC version is 6.21.

Joined: Dec 2002
Posts: 3,547
S
Hoopy frood
Offline
Hoopy frood
S
Joined: Dec 2002
Posts: 3,547
I don't have version 6.21 and I know that the highlight feature was moved into the address book.

Maybe you should upgrade to the latest version. Here's a way to do it in 6.31.

Code:
alias sendkeys {
  var %object = sendkeys $+ $ticks
  .comopen %object WScript.Shell
  if ($com(%object)) { .comclose %object $com(%object,SendKeys,3,bstr,$1-) }
}

alias highlight { 
  sendkeys $+(%,tb)
  sendkeys $+(%,n)
  sendkeys {ENTER}
  echo -a Highlight is now $iif($highlight == $false,on.,off.)
}


It flashes suddenly because it opens up the dialog, checks/uncheks option and closes it again. I'm sure there'll be an actual command one day though.. smile

Joined: Oct 2003
Posts: 3,918
A
Hoopy frood
Offline
Hoopy frood
A
Joined: Oct 2003
Posts: 3,918
what about

sendkeys $(%tb %n {ENTER},0)


- argv[0] on EFnet #mIRC
- "Life is a pointer to an integer without a cast"
Joined: Dec 2002
Posts: 3,547
S
Hoopy frood
Offline
Hoopy frood
S
Joined: Dec 2002
Posts: 3,547
Didn't seem to work for me dude. It works without the {ENTER} but when I put it back it doesn't.

Joined: Feb 2006
Posts: 546
J
Fjord artisan
Offline
Fjord artisan
J
Joined: Feb 2006
Posts: 546
space between %n and {ENTER} renders that useless

//sendkeys % $+ tb%n{ENTER}


"The only excuse for making a useless script is that one admires it intensely" - Oscar Wilde

Link Copied to Clipboard