Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Global $path, $file
- DirSetZoneIdentifier(@ScriptDir & '\X64bit\')
- DirSetZoneIdentifier(@ScriptDir & '\X86bit\')
- DirSetZoneIdentifier(@ScriptDir & '\X86-X64bit\')
- ;~ MsgBox(64, "", $path & @CRLF & $file)
- Func FileSetZoneIdentifier($Filename, $ZoneId=0)
- MsgBox(0,'','11')
- Local $File = FileOpen($Filename & ":Zone.Identifier:$DATA", 2)
- MsgBox(0,'','12')
- FileWrite($File, "[ZoneTransfer]" & @CRLF & "ZoneId=" & $ZoneId)
- MsgBox(0,'','13')
- FileClose($File)
- MsgBox(0,'','14 ')
- EndFunc
- Func DirSetZoneIdentifier($path, $ZoneId=0)
- MsgBox(0,'','1')
- Local $search = FileFindFirstFile($path & "*.exe"), $file
- MsgBox(0,'','2')
- If $search = -1 Then Return False
- MsgBox(0,'','3')
- Do
- MsgBox(0,'','4')
- $file = FileFindNextFile($search)
- MsgBox(0,'','4')
- If @error Then ExitLoop
- MsgBox(0,'','5')
- MsgBox(64, "", $path & $file)
- MsgBox(0,'','6')
- FileSetZoneIdentifier($path & $file, $ZoneId)
- MsgBox(0,'','7')
- Until False
- MsgBox(0,'','8')
- FileClose($search)
- MsgBox(0,'','9')
- Return True
- MsgBox(0,'','10')
- EndFunc
Add Comment
Please, Sign In to add comment