|  | 
|  |  
| | 
| 
| 
|  |  
| 
Joined:  Aug 2016 Posts: 57 Babel fish |  
|   Babel fish Joined:  Aug 2016 Posts: 57 | 
Klez, most of the things you said is possible to do with mirc scripting. To know if mIRC is running with admin privileges. ; $isadmin
; Returns $true or null
alias isadmin {
  if (!$isid) return
  set -l %a isadmin_ $+ $ticks $+ $rand(1111,9999))
  if ($com(locator_ $+ %a)) .comclose locator_ $+ %a
  .comopen locator_ $+ %a WbemScripting.SWbemLocator
  if ($comerr) return
  if ($com(services_ $+ %a)) .comclose services_ $+ %a
  if (!$com(locator_ $+ %a,ConnectServer,3,dispatch* services_ $+ %a)) || ($comerr) return
  .comclose locator_ $+ %a
  if ($com(os_ $+ %a)) .comclose os_ $+ services_ $+ %a
  if (!$com(services_ $+ %a,ExecQuery,3,bstr,Select * from Win32_OperatingSystem,dispatch* os_ $+ %a)) || ($comerr) return
  .comclose services_ $+ %a
  if ($com(os_ $+ %a,Count,3)) && ($comval(os_ $+ %a,1,SystemDirectory)) set -l %sysdir $v1 $+ \
  else return
  .comclose os_ $+ %a
  .fopen -o %a $qt(%sysdir $+ %a $+ .tmp)
  .fwrite %a $!true
  .fclose %a
  set -l %read $read(%sysdir $+ %a $+ .tmp)
  .remove $qt(%sysdir $+ %a $+ .tmp)
  return %read
}Run with wait ; run2 -N <filename> [parameters]
; N = intWindowStyle in https://msdn.microsoft.com/en-us/library/d5fk67ky(v=vs.85).aspx
; //run2 cmd.exe | echo -s cmd.exe closed!
alias run2 {
  set -l %s 1
  if ($regex($1,/^-(\d+)$/)) {
    %s = $regml(1)
    tokenize 32 $2-
  }
  set -l %a run_ $+ $ticks $+ $rand(1111,9999))
  if ($com(%a)) .comclose %a
  .comopen %a WScript.Shell
  if ($comerr) return
  noop $com(%a,Run,1,bstr,$1-,int,%s,bool,true)
  .comclose %a
}UAC ; $uac(File[,Arguments[,Directory[,Show]]])
; $uac(mirc.exe,$null,$nofile($mircexe))
; https://msdn.microsoft.com/pt-br/library/windows/desktop/gg537745(v=vs.85).aspx
alias uac {
  if (!$isid) || (!$1) || (($3) && (!$isdir($3))) || (($4) && (!$regex($4,/^\d+$/))) return
  set -l %s 1
  if ($regml(1)) %s = $v1
  set -l %arg $2
  set -l %dir $3
  set -l %a uac_ $+ $ticks $+ $rand(1111,9999))
  if ($com(%a)) .comclose %a
  .comopen %a Shell.Application
  if ($comerr) return
  if ($com(%a,ShellExecute,3,bstr,$1,bstr,%arg,bstr,%dir,bstr,runas,int,%s)) set -l %r 1
  .comclose %a
  return %r
}
Last edited by rockcavera; 17/02/17 01:41 PM.
 |  |  |  
| 
| Entire Thread |  
 
|    Ability to /rline text from channels, queries, etc | Raccoon | 27/01/15 10:52 PM |  
|    Re: Ability to /rline text from channels, queries, etc | Masoud | 28/01/15 10:54 AM |  
|    Re: Ability to /rline text from channels, queries, etc | Raccoon | 28/01/15 11:18 AM |  
|    Re: Ability to /rline text from channels, queries, etc | Anonymous | 25/02/15 12:59 AM |  
|    Re: Ability to /rline text from channels, queries, etc | Raccoon | 05/02/17 09:36 PM |  
|    Re: Ability to /rline text from channels, queries, etc | rockcavera | 07/02/17 11:04 PM |  
|    Re: Ability to /rline text from channels, queries, etc | klez | 17/02/17 07:37 AM |  
|    Re: Ability to /rline text from channels, queries, etc | Sat | 17/02/17 10:07 AM |  
|    Re: Ability to /rline text from channels, queries, etc | rockcavera | 17/02/17 01:06 PM |  
|    Re: Ability to /rline text from channels, queries, etc | klez | 18/02/17 12:19 PM |  
|    Re: Ability to /rline text from channels, queries, etc | Wims | 18/02/17 12:24 PM |  
|    Re: Ability to /rline text from channels, queries, etc | klez | 18/02/17 12:41 PM |  |  | 
 |  
| 
 |  |  |