mIRC Home    About    Download    Register    News    Help

Print Thread
#50247 19/09/03 07:10 AM
Joined: Jan 2003
Posts: 148
K
Knappen Offline OP
Vogon poet
OP Offline
Vogon poet
K
Joined: Jan 2003
Posts: 148
I wanna make a check box option in my script where can mark if i want to make the script start up automaticly when windows starts.. I found this alias:

Code:
  
alias regwrite {  
var %a = regwrite $+ $ticks  
.comopen %a WScript.Shell  if $comerr { return 0 } 
 if d isin $3 { var %3 = REG_DWORD, %type = ui4 } 
 elseif b isin $3 { var %3 = REG_BINARY, %type = ui4 }  
else { var %3 = REG_SZ, %type = bstr }  
if $com(%a,RegWrite,3,bstr,$1,%type,$2,bstr,%3) { 
.comclose %a    
return 1  
 }  
.comclose %a  return 0 
}


I wanna be able to delete the key that make the script able to start up = a $regdel alias. Can any one make that for me?

Thanks smile

#50248 19/09/03 10:30 AM
Joined: Jan 2003
Posts: 2,523
Q
Hoopy frood
Offline
Hoopy frood
Q
Joined: Jan 2003
Posts: 2,523
Code:
[color:green]; Syntax: $regdel(<key/value>)
; Specify a key-name by ending <key/value> with a final backslash;
; leave it off to specify a value-name.[/color]
alias regdel {
  var %a = regdel $+ $ticks
  .comopen %a WScript.Shell
  if $comerr { return 0 }
  var %b = $com(%a,RegDelete,3,bstr,$1)
  .comclose %a
  return %b
}


/.timerQ 1 0 echo /.timerQ 1 0 $timer(Q).com
#50249 20/09/03 10:22 AM
Joined: Jan 2003
Posts: 148
K
Knappen Offline OP
Vogon poet
OP Offline
Vogon poet
K
Joined: Jan 2003
Posts: 148
Thanks! I`ll try it! smile


Link Copied to Clipboard