Page 1 sur 1
[..] Comment récupérer le lien direct avec le nom du fichier à partir d'une URL dynamique ?
Posté : lun. 26 mars 2018 00:54
par Hackoo
Salut tout le monde
Je me demande est-ce-qu'il y a un moyen pour récupérer le lien direct avec le nom du fichier (
RogueKiller_setup.exe) de cette URL afin de le télécharger par Autoit ?
L'URL en question :
http://download.adlice.com/api/?action= ... type=setup
Merci !
Re: [..] Comment récupérer le lien direct avec le nom du fichier à partir d'une URL dynamique ?
Posté : lun. 26 mars 2018 09:53
par walkson
Bonjour,
InetGet()
ou indirectement ShellExecute()
Re: [..] Comment récupérer le lien direct avec le nom du fichier à partir d'une URL dynamique ?
Posté : lun. 26 mars 2018 11:30
par Hackoo
Salut
Mon but est de faire une commande externe que je vais l'utiliser en ligne de commande ou bien dans un script batch avec une barre de progression, donc ce que je cherche pour télécharger le fichier en question est d'obtenir son lien diect càd qui a une extension à la fin de l'URL
.exe ou bien
.zip ou bien
.rar etc ...
mais dans cette dernière URL je n'ai aucune information sur l'obtention de tel lien direct ? j'espére que vous me comprenez ce que je veux dire ?
Donc, ma question est-ce-qu'il y a un moyen de le retrouver par une regexp ou autre astuce ?
Voilà le code source du
Downloader.au3
► Afficher le texteDownloader.au3
#Region ;**** Directives created by AutoIt3Wrapper_GUI ****#AutoIt3Wrapper_Icon=Download.ico#AutoIt3Wrapper_UseUpx=y#AutoIt3Wrapper_Change2CUI=y#EndRegion ;**** Directives created by AutoIt3Wrapper_GUI ****#include <Inet.au3>#include <File.au3>#include <WinAPI.au3>If $CmdLine[0] = 0 Then $dll = DllOpen("Kernel32.dll") $hnd = _WinAPI_GetStdHandle(1) ;Get the AutoIt process's standard output handle _WinAPI_SetConsoleTextAttribute
($hnd, "11", $dll) ConsoleWrite(@CRLF & _
' ************************************************************************************************'& @CRLF & _
' Extrenal Command Line for downloading files from internet written in Autoit by Hackoo 2018' & @CRLF & _
' ************************************************************************************************'& @CRLF & _
' Usage : ' & @ScriptName & ' ' & chr(34) & "[Link]" & chr(34) & " Optional " & chr(34) & "[FileName]" & chr(34)) Sleep(8000) ExitElse _DownloadWithProgress
($CmdLine[1], "")EndIf;-----------------------------------------------------------------------------------------------------------------------------------------------------------Func _DownloadWithProgress
($sURL, $sFileName = "") Local $hDownload, $iSizeBytes = InetGetSize($sURL) Local $iH, $iM, $iS, $iTicks, $iCompletedBytes, $nPercent, $nElapsedTime, $nBPS, $nT = TimerInit() If $sFileName = "" Then If CheckDirectLink
($sURL) = 1 Then $hDownload = InetGet($sURL, StringTrimLeft($sURL, StringInStr($sURL, "/", 0, -1)), 1, 1) Else $sURL = _GetHeaderLocation
($sURL) $hDownload = InetGet($sURL, StringTrimLeft($sURL, StringInStr($sURL, "/", 0, -1)), 1, 1) EndIf Else $hDownload = InetGet($sURL, $sFileName, 0, 1) EndIf ProgressOn(" Download is in progress . . . . ", "0% done - 0 Kb/s", "Remaining time - 00:00:00", Default, Default, 18) Do $iCompletedBytes = InetGetInfo
($hDownload, 0) $nPercent = $iCompletedBytes * 100 / $iSizeBytes $nElapsedTime = TimerDiff($nT) / 1000 $nBPS = $iCompletedBytes / $nElapsedTime $iTicks = $iSizeBytes / $nBPS - $nElapsedTime $iH = Int($iTicks / 3600) $iTicks = Mod($iTicks, 3600) $iM = Int($iTicks / 60) $iS = Mod($iTicks, 60) ProgressSet($nPercent, "Remaining - " & StringFormat("%02d:%02d:%02d", $iH, $iM, $iS), StringFormat("%.1f", Round($nPercent, 1)) & "% done ! " & Int($nBPS / 1024) & " Kb/s") Sleep(50) Until InetGetInfo
($hDownload, 2) ProgressSet(100, "", "The download is complete !") Sleep(3000) ProgressOff()EndFunc ;==>_DownloadWithProgress;-----------------------------------------------------------------------------------------------------------------------------------------------------------; #FUNCTION# ====================================================================================================================; Name...........: _WinAPI_SetConsoleTextAttribute; Description ...: Changes the text and/or background color of text in the Windows console.; Syntax.........: _WinAPI_SetConsoleTextAttribute($hConsole, $iColor, $hDLL = "Kernel32.dll"); Parameters ....: $hConsole - Handle to the console screen buffer; $iColor - Color style to apply to the console.; $hDLL - Handle to the DLL to call. (Leave blank to open Kernel32.dll each call); Return values .: Success - True; Failure - False; Author ........: Ken Piper (Kealper); Modified.......:; Remarks .......:; Related .......:; Link ..........: @@MsdnLink@@ SetConsoleTextAttribute; Example .......:; ===============================================================================================================================Func _WinAPI_SetConsoleTextAttribute
($hConsole, $iColor, $hDLL = "Kernel32.dll") $ret = DllCall($hDLL, "BOOL", "SetConsoleTextAttribute", "HANDLE", $hConsole, "WORD", $iColor) If @error Then Return SetError(@error, @extended, False) Return $ret[0]EndFunc ;==>_WinAPI_SetConsoleTextAttribute;===============================================================================================================================Func _GetHeaderLocation
($sURL);https://stackoverflow.com/questions/32655302/how-to-get-http-response-header-in-vbscript?answertab=active#tab-topConst $WHR_EnableRedirects = 6Local $oHTTP = ObjCreate("winhttp.winhttprequest.5.1")If Not @error Then $oHTTP.Option($WHR_EnableRedirects) = False ;disable redirects $oHTTP.Open("HEAD",$sURL, False) $oHTTP.Send $GetLocation = $oHTTP.GetResponseHeader("Location") ;an error occurs if not exist Return $GetLocationEndIfEndFunc;===============================================================================================================================Func CheckDirectLink
($url) Local $Pattren = "(?i)(.exe|.zip|.rar|.msi|.vbs|.bat|.hta|.txt|.log|.doc" & _
"|.docx|.xls|.xlsx|.pdf|.mp3|.mp4|.avi|.png|.jpg|.jpeg|.bmp|.gif)" Local $return = StringRegExp($url,$Pattren,"",1) Return $returnEndFunc;===============================================================================================================================
Code Batch pour télécharger Malwarebytes v 3.4.4 avec une commande externe en Autoit avec une barre de progression :
@echo off
Mode
70,3 & color 0A
Title Download
with Progress Bar using Autoit by Hackoo
2018echo
(echo Please Wait a
While ... The download is
in progress
...Set "URL=https://downloads.malwarebytes.com/file/mb3/"Call Download
"%URL%"for /f
"delims=" %%a in ('Dir /b "%~dp0*.exe" ^| find /I "setup"') do ( Start
"" "%%a")Exit
Re: [..] Comment récupérer le lien direct avec le nom du fichier à partir d'une URL dynamique ?
Posté : lun. 26 mars 2018 14:41
par Tlem
Bonjour.
De plus en plus de site utilisent des pages php qui ne permet pas de connaitre l'adresse d'origine, du coup impossible d'avoir dans certains cas cette adresse.
Pour le cas de Malwarebytes, vous pouvez utiliser votre navigateur pour télécharger l'installateur et sur l'historique des téléchargement extraire le lien d'origine.
Ce qui donne pour malwarebyes :
https://data-cdn.mbamupdates.com/web/mb ... 0.4478.exe
Après sur certains sites, il est possible de connaitre le nom de l'exécutable à télécharger en fouillant l'historique des versions, mais cela ne fonctionne pas tout le temps.
Si vous arrivez à surveiller les échanges entre le logiciel concerné et le site de l'éditeur, vous pouvez aussi arriver à connaitre le lien de contrôle du numéro de version, mais là encore, rien de fiable à 100%.
Re: [..] Comment récupérer le lien direct avec le nom du fichier à partir d'une URL dynamique ?
Posté : lun. 26 mars 2018 18:10
par orax
C'est pareil sur ce forum, avec les avatars ; l'emplacement où est stocké l'image n'est pas indiqué dans l'URL. Par exemple, quand je télécharge le fichier
download/file.php?avatar=4404_1331030491.jpg dans un logiciel de téléchargement, le nom du fichier qui sera enregistré est 4404.jpg. Ce nom de fichier est apparemment indiqué dans les en-têtes HTTP.
Code : Tout sélectionner
HTTP/1.1 200 OK
Date: Mon, 26 Mar 2018 13:05:31 GMT
Content-Type: image/jpeg
Content-Length: 3580
Server: Apache
X-Powered-By: PHP/7.1.13
Cache-Control: public
Content-Disposition: inline; filename*=UTF-8''4404.jpg
Expires: Tue, 26 Mar 2019 13:05:31 GMT
Last-Modified: Tue, 06 Mar 2012 10:41:31 GMT
X-IPLB-Instance: 5281
Re: [..] Comment récupérer le lien direct avec le nom du fichier à partir d'une URL dynamique ?
Posté : mar. 27 mars 2018 16:01
par Hackoo
Suite à la remarque de orax, j'ai fait un petit vbscript avec une barre de progression en HTA.
Multi-Downloader.vbs pour télécharger des fichiers avec des liens directs ou dynamiques
► Afficher le texteMulti-Downloader.vbs
Option Explicit
If AppPrevInstance
() Then MsgBox "The script is already launching" & vbCrlf
&_
CommandLineLike
(WScript
.ScriptName),VbExclamation
,"The script is already launching" WScript
.Quit Else Const Copyright
= " by Hackoo 2018" Dim Title : Title
= "Get Header Location and download file" & Copyright
Const WHR_EnableRedirects
= 6 Dim Default_Link
,Base_Link
,Dynamic_Link
,Flag
,Question
,DirectLink
,Save2File
Dim fso
,ws
,Temp
,WaitingMsg
,oExec
Default_Link
= "https://download.toolslib.net/download/file/1/1388" Set fso
= CreateObject
("Scripting.FileSystemObject") Set ws
= CreateObject
("WScript.Shell") Temp
= ws
.ExpandEnvironmentStrings("%Temp%")' "https://downloads.malwarebytes.com/file/mb3/" 'Tested OK
==> Malwarebytes v3
.4
.4
' "https://download.toolslib.net/download/file/1/1388" 'Tested OK
==> Adwcleaner v7
.0
.8
.0
' "https://autoitscript.fr/forum/download/file.php?avatar=10_1293979860.png" 'Tested OK
==> Avatar Tlem
' "https://autoitscript.fr/forum/download/file.php?avatar=4404_1331030491.jpg" 'Tested OK
==> Avatar Hackoo
' "https://autoitscript.fr/forum/download/file.php?avatar=4001_1422642041.gif" 'Tested OK
==> Avatar walkson
' "https://autoitscript.fr/forum/download/file.php?avatar=1520_1467716891.png" 'Tested OK
==> Avatar orax
' "https://www.google.tn/images/branding/googlelogo/1x/googlelogo_color_272x92dp.png" Tested OK ==> a direct link example
' "https://www.developpez.net/forums/avatars/312790-hackoofr.gif" Tested OK
==> a direct link example
Base_Link
= InputBox("Copy and paste your link here to get the response header",Title
,Default_Link
) If CheckDirectLink
(Base_Link
) = True And Instr
(Base_Link
,"php") = 0 Then 'Check if it is a direct link
Save2File = GetFileNamefromDirectLink(Base_Link)
WaitingMsg = "Please wait ... The download of : <font color=Yellow>"& DblQuote(Save2File) & "</font> is in progress ..."
Call CreateProgressBar(Title,WaitingMsg)'Creation of Waiting Bar
Call LaunchProgressBar
() 'Launch of the Waiting Bar
Call Download(Base_Link,Save2File)
pause(3)
Call CloseProgressBar()
MsgBox "The download of the file : "& Save2File & vbCrlf &_
"is Completed !",vbInformation,Title
wscript.Quit()
End If
Call GetHeaderLocation(Base_Link)
If Flag = True And CheckDirectLink(GetHeaderLocation(Base_Link)) = True Then 'Checking
for a direct link of Malwarebytes
Save2File
= GetFileNamefromDirectLink
(GetHeaderLocation
(Base_Link
)) DirectLink
= GetHeaderLocation
(Base_Link
)'wscript.echo DirectLink & vbCrlf & Save2File
Question = MsgBox("Did you want to download this file ?" & vbCrlf &_
Save2File,vbQuestion+vbYesNo,Title)
If Question = vbYes Then
WaitingMsg = "Please wait ... The download of : <font color=Yellow>"& DblQuote(Save2File) & "</font> is in progress ..."
Call CreateProgressBar(Title,WaitingMsg)'Creation of Waiting Bar
Call LaunchProgressBar
() 'Launch of the Waiting Bar
Call Download(DirectLink,Save2File)
Call CloseProgressBar()
MsgBox "The download of the file : "& Save2File & vbCrlf &_
"is Completed !",vbInformation,Title
Wscript.Quit()
End If
ElseIf Instr(Base_Link,"toolslib") <> 0 And Flag = True Then 'for Adwcleaner
Dynamic_Link
= Extract_Dynamic_Link
(GetDataFromURL
(Base_Link
,"Get", "")) Save2File
= GetFileName
(GetHeaderLocation
(Dynamic_Link
)) Question
= MsgBox("The Dynamic Link is = "& Dynamic_Link
& vbcrlf
& vbcrlf
&_
"Response of The Dynamic Link is : "& vbcrlf
& GetHeaderLocation
(Dynamic_Link
) & vbCrlf
& vbCrlf
&_
"Extracted FileName is = " & Save2File
,vbYesNo
+vbQuestion
,Title
) If Question
= vbYes
Then WaitingMsg
= "Please wait ... The download of : <font color=Yellow>"& DblQuote
(Save2File
) & "</font> is in progress ..." Call CreateProgressBar
(Title
,WaitingMsg
)'Creation of Waiting Bar
Call LaunchProgressBar() 'Launch of the Waiting Bar
Call Download
(Dynamic_Link
,Save2File
) Call CloseProgressBar
() MsgBox "The download of the file : "& Save2File
& vbCrlf
&_
"is Completed !",vbInformation
,Title
Else Wscript
.Quit() End
If ElseIf Instr
(Base_Link
,"php") > 0 And Flag
= False Then Save2File
= GetFileName
(GetHeaderLocation
(Base_Link
)) ' for site of autoitscript.fr
Question = MsgBox("Did you want to download this file ?" & vbCrlf &_
Save2File,vbQuestion+vbYesNo,Title)
If Question = vbYes Then
WaitingMsg = "Please wait ... The download of : <font color=Yellow>"& DblQuote(Save2File) & "</font> is in progress ..."
Call CreateProgressBar(Title,WaitingMsg)'Creation of Waiting Bar
Call LaunchProgressBar
() 'Launch of the Waiting Bar
Call Download(Base_Link,Save2File)
pause(3)
Call CloseProgressBar()
MsgBox "The download of the file : "& Save2File & vbCrlf &_
"is Completed !",vbInformation,Title
Else
Wscript.Quit()
End If
End If
End If
'------------------------------------------------Function GetHeaderLocation
(URL
) On Error Resume
Next Dim h
,GetLocation
Set h
= CreateObject
("WinHttp.WinHttpRequest.5.1") h
.Option(WHR_EnableRedirects
) = False h
.Open "HEAD", URL
, False h
.Send() GetLocation
= h
.GetResponseHeader("Location") If Err
= 0 Then Flag
= True GetHeaderLocation
= GetLocation
Else Flag
= False GetHeaderLocation
= h
.GetResponseHeader("Content-Disposition") End
If End Function
'---------------------------------------------
Function GetFileName(Data)
Dim regEx, Match, Matches,FileName
Set regEx = New RegExp
regEx.Pattern = "\x27{2}(\w.*)"
regEx.IgnoreCase = True
regEx.Global = True
If regEx.Test(Data) Then
Set Matches = regEx.Execute(Data)
For Each Match in Matches
FileName = Match.subMatches(0)
Next
Else
Set regEx = New RegExp
regEx.Pattern = "\x22(\w.*)\x22"
regEx.IgnoreCase = True
regEx.Global = True
Set Matches = regEx.Execute(Data)
For Each Match in Matches
FileName = Match.subMatches(0)
Next
End If
GetFileName = FileName
End Function
'---------------------------------------------Function Extract_Dynamic_Link
(Data
) Dim regEx
, Match
, Matches
,Dynamic_Link
Set regEx
= New RegExp
regEx
.Pattern = Base_Link
& "\?s=[^""]*" regEx
.IgnoreCase = True regEx
.Global = True Set Matches
= regEx
.Execute(Data
) For Each Match
in Matches
Dynamic_Link
= Match
.Value Next Extract_Dynamic_Link
= Dynamic_Link
End Function
'------------------------------------------------
Function GetDataFromURL(strURL, strMethod, strPostData)
Dim lngTimeout
Dim strUserAgentString
Dim intSslErrorIgnoreFlags
Dim blnEnableRedirects
Dim blnEnableHttpsToHttpRedirects
Dim strHostOverride
Dim strLogin
Dim strPassword
Dim strResponseText
Dim objWinHttp
lngTimeout = 59000
strUserAgentString = "http_requester/0.1"
intSslErrorIgnoreFlags = 13056 ' 13056: ignore all err
, 0: accept no err
blnEnableRedirects
= True blnEnableHttpsToHttpRedirects
= True strHostOverride
= "" strLogin
= "" strPassword
= "" Set objWinHttp
= CreateObject
("WinHttp.WinHttpRequest.5.1") objWinHttp
.SetTimeouts lngTimeout
, lngTimeout
, lngTimeout
, lngTimeout
objWinHttp
.Open strMethod
, strURL
If strMethod
= "POST" Then objWinHttp
.setRequestHeader "Content-type", _
"application/x-www-form-urlencoded" End
If If strHostOverride
<> "" Then objWinHttp
.SetRequestHeader "Host", strHostOverride
End
If objWinHttp
.Option(0) = strUserAgentString
objWinHttp
.Option(4) = intSslErrorIgnoreFlags
objWinHttp
.Option(6) = blnEnableRedirects
objWinHttp
.Option(12) = blnEnableHttpsToHttpRedirects
If (strLogin
<> "") And (strPassword
<> "") Then objWinHttp
.SetCredentials strLogin
, strPassword
, 0 End
If On Error Resume
Next objWinHttp
.Send(strPostData
) If Err
.Number = 0 Then If objWinHttp
.Status = "200" Then GetDataFromURL
= objWinHttp
.ResponseText Else GetDataFromURL
= "HTTP " & objWinHttp
.Status & " " & _
objWinHttp
.StatusText End
If Else GetDataFromURL
= "Error " & Err
.Number & " " & Err
.Source & " " & _
Err
.Description End
If On Error GoTo
0 Set objWinHttp
= Nothing
End Function
'------------------------------------------------
Sub Download(URL,Save2File)
Dim File,Line,BS,ws
On Error Resume Next
Set File = CreateObject("WinHttp.WinHttpRequest.5.1")
File.Open "GET",URL, False
File.Send()
If err.number <> 0 then
Line = Line & vbcrlf & "Error Getting File"
Line = Line & vbcrlf & "Error " & err.number & "(0x" & hex(err.number) & ") " & vbcrlf &_
err.description
Line = Line & vbcrlf & "Source " & err.source
MsgBox Line,vbCritical,"Error getting file"
Err.clear
wscript.quit
End If
If File.Status = 200 Then ' File exists
and it is ready
to be downloaded
Set BS
= CreateObject
("ADODB.Stream") Set ws
= CreateObject
("wscript.Shell") BS
.type = 1 BS
.open BS
.Write File
.ResponseBody BS
.SaveToFile Save2File
, 2 ElseIf File
.Status = 404 Then MsgBox "File Not found : " & File
.Status,vbCritical
,"Error File Not Found" Else MsgBox "Unknown Error : " & File
.Status,vbCritical
,"Error getting file" End
IfEnd Sub
'------------------------------------------------
Function GetFileNamefromDirectLink(URL)
Dim ArrFile,FileName
ArrFile = Split(URL,"/")
FileName = ArrFile(UBound(ArrFile))
GetFileNamefromDirectLink = FileName
End Function
'------------------------------------------------Function CheckDirectLink
(URL
) Dim regEx
Set regEx
= New RegExp
regEx
.Pattern = "(.exe|.zip|.rar|.msi|.vbs|.bat|.hta|.txt|.log|.doc" & _
"|.docx|.xls|.xlsx|.pdf|.mp3|.mp4|.avi|.png|.jpg|.jpeg|.bmp|.gif)" regEx
.IgnoreCase = True regEx
.Global = False If regEx
.Test(URL
) Then CheckDirectLink
= True End
IfEnd Function
'------------------------------------------------
'**********************************************************************************************Sub CreateProgressBar
(Title
,WaitingMsg
) Dim ws
,fso
,f
,f2
,ts
,ts2
,Ligne
,i
,fread
,LireTout
,NbLigneTotal
,Temp
,PathOutPutHTML
,fhta
,oExec
Set ws
= CreateObject
("wscript.Shell") Set fso
= CreateObject
("Scripting.FileSystemObject") Temp
= WS
.ExpandEnvironmentStrings("%Temp%") PathOutPutHTML
= Temp
& "\Barre.hta" Set fhta
= fso
.OpenTextFile(PathOutPutHTML
,2,True) fhta
.WriteLine "<HTML>" fhta
.WriteLine "<HEAD>" fhta
.WriteLine "<Title> " & Title
& "</Title>" fhta
.WriteLine "<HTA:APPLICATION" fhta
.WriteLine "ICON = ""magnify.exe"" " fhta
.WriteLine "BORDER=""THIN"" " fhta
.WriteLine "INNERBORDER=""NO"" " fhta
.WriteLine "MAXIMIZEBUTTON=""NO"" " fhta
.WriteLine "MINIMIZEBUTTON=""NO"" " fhta
.WriteLine "SCROLL=""NO"" " fhta
.WriteLine "SYSMENU=""NO"" " fhta
.WriteLine "SELECTION=""NO"" " fhta
.WriteLine "SINGLEINSTANCE=""YES"">" fhta
.WriteLine "</HEAD>" fhta
.WriteLine "<BODY text=""white""><CENTER>" fhta
.WriteLine "<marquee DIRECTION=""LEFT"" SCROLLAMOUNT=""3"" BEHAVIOR=ALTERNATE><font face=""Comic sans MS"">" & WaitingMsg
&"</font></marquee>" fhta
.WriteLine "<img src=""data:image/gif;base64,R0lGODlhgAAPAPIAAP////INPvvI0/q1xPVLb/INPgAAAAAAACH/C05FVFNDQVBFMi4wAwEAAAAh/hpDcmVhdGVkIHdpdGggYWpheGxvYWQuaW5mbwAh+QQJCgAAACwAAAAAgAAPAAAD5wiyC/6sPRfFpPGqfKv2HTeBowiZGLORq1lJqfuW7Gud9YzLud3zQNVOGCO2jDZaEHZk+nRFJ7R5i1apSuQ0OZT+nleuNetdhrfob1kLXrvPariZLGfPuz66Hr8f8/9+gVh4YoOChYhpd4eKdgwDkJEDE5KRlJWTD5iZDpuXlZ+SoZaamKOQp5wAm56loK6isKSdprKotqqttK+7sb2zq6y8wcO6xL7HwMbLtb+3zrnNycKp1bjW0NjT0cXSzMLK3uLd5Mjf5uPo5eDa5+Hrz9vt6e/qosO/GvjJ+sj5F/sC+uMHcCCoBAAh+QQJCgAAACwAAAAAgAAPAAAD/wi0C/4ixgeloM5erDHonOWBFFlJoxiiTFtqWwa/Jhx/86nKdc7vuJ6mxaABbUaUTvljBo++pxO5nFQFxMY1aW12pV+q9yYGk6NlW5bAPQuh7yl6Hg/TLeu2fssf7/19Zn9meYFpd3J1bnCMiY0RhYCSgoaIdoqDhxoFnJ0FFAOhogOgo6GlpqijqqKspw+mrw6xpLCxrrWzsZ6duL62qcCrwq3EsgC0v7rBy8PNorycysi3xrnUzNjO2sXPx8nW07TRn+Hm3tfg6OLV6+fc37vR7Nnq8Ont9/Tb9v3yvPu66Xvnr16+gvwO3gKIId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KSdprKotqqttK+7sb2zq6y8wcO6xL7HwMbLtb+3zrnNycKp1bjW0NjT0cXSzMLK3uLd5Mjf5uPo5eDa5+Hrz9vt6e/qosO/GvjJ+sj5F/sC+uMHcCCoBAA7AAAAAAAAAAAA"" />" fhta
.WriteLine "</CENTER></BODY></HTML>" fhta
.WriteLine "<SCRIPT LANGUAGE=""VBScript""> " fhta
.WriteLine "Set ws = CreateObject(""wscript.Shell"")" fhta
.WriteLine "Temp = WS.ExpandEnvironmentStrings(""%Temp%"")" fhta
.WriteLine "Sub window_onload()" fhta
.WriteLine " CenterWindow 490,110" fhta
.WriteLine " Self.document.bgColor = ""DarkOrange"" " fhta
.WriteLine " End Sub" fhta
.WriteLine " Sub CenterWindow(x,y)" fhta
.WriteLine " Dim iLeft,itop" fhta
.WriteLine " window.resizeTo x,y" fhta
.WriteLine " iLeft = window.screen.availWidth/2 - x/2" fhta
.WriteLine " itop = window.screen.availHeight/2 - y/2" fhta
.WriteLine " window.moveTo ileft,itop" fhta
.WriteLine "End Sub" fhta
.WriteLine "</script>" fhta
.closeEnd Sub
'**********************************************************************************************
Sub LaunchProgressBar()
Set oExec = Ws.Exec("mshta.exe " & Temp & "\Barre.hta")
End Sub
'**********************************************************************************************Sub CloseProgressBar
() oExec
.TerminateEnd Sub
'**********************************************************************************************
Function DblQuote(Str)
DblQuote = Chr(34) & Str & Chr(34)
End Function
'**********************************************************************************************Sub Pause
(Secs
) Wscript
.Sleep(Secs
* 1000) End Sub
'**********************************************************************************************
Function AppPrevInstance()
With GetObject("winmgmts:" & "{impersonationLevel=impersonate}!\\.\root\cimv2")
With .ExecQuery("SELECT * FROM Win32_Process WHERE CommandLine LIKE " & CommandLineLike(WScript.ScriptFullName) & _
" AND CommandLine LIKE '%WScript%
' OR CommandLine LIKE '%cscript%
'")
AppPrevInstance = (.Count > 1)
End With
End With
End Function
'*********************************************************************************************Function CommandLineLike
(ProcessPath
) ProcessPath
= Replace
(ProcessPath
, "\", "\\") CommandLineLike
= "'%" & ProcessPath
& "%'" End Function
'*********************************************************************************************
Donc, il me reste juste quelqu'un parmi vous m'aide a le traduire en Autoit
