mIRC Homepage
Posted By: parisien paste the clipboard in a variable ? - 19/08/07 11:37 PM
Hello


i have a popup like this :

Msg:{
var %test $$?="toto"
/msg %test abcdef
}

I would like to change is so that instead of opening a dialog box for %test, i would like that mirc paste automaticly what is in the clipboard of the pc, in %test.

i explain better :

i want a popup like that :

Msg:{
/msg %test abcdef
}

and %test must be the last thing i put in the clipboard of windows with Ctrl C or Ctrl X.

do you know how to do ?

thank you


PS. i am sorry my english is not good at all. I hope you will understand my question.
Posted By: Horstl Re: paste the clipboard in a variable ? - 20/08/07 12:15 AM
Code:
menu channel,query {
  $iif((!$cb),$style(2)) msg clipboard content to $active $iif(($cb(1)),$+([lines,$chr(58) $cb(0),])) : {
    var %nr = 1
    while ($cb(%nr)) { msg $active $v1 ABCDEF | inc %nr }
  }
}

With the $cb identifier you can:
- return whether or not there's something in the clipboard at all : if ($cb)
- return how manly $crlf delimited lines the clipboard holds: $cb(0)
- return single lines of the clipboard content: $cb(N)
Posted By: parisien Re: paste the clipboard in a variable ? - 25/08/07 07:54 PM
it works...

thank youuuuuuuuuuuuuuuuuuu
© mIRC Discussion Forums