Jump to content

Autoitte Birden Fazla Exe'yi Nasıl Gömeriz?


x_files_x

Recommended Posts

Arkadaslar elimde bi kod var bununla berber bir kac tanede küçük program varnasıl tamamını bir exeye sıkıltırabilirim hani fileinstall komutu var ama tek olmadıgı icin yapamadım kodlar burda;

#NoTrayIcon

#Region ;**** Directives created by AutoIt3Wrapper_GUI ****

#AutoIt3Wrapper_icon=G:\iKONLAR\Alpha Dista Icon 20.ico

#EndRegion ;**** Directives created by AutoIt3Wrapper_GUI ****

#include <ButtonConstants.au3>

#include <GUIConstantsEx.au3>

#include <WindowsConstants.au3>

$Form1 = GUICreate("SOHBET SCRiPT", 273, 52, 192, 124)

$Button1 = GUICtrlCreateButton(" MSN ", 8, 8, 81, 33, $WS_GROUP)

$Button2 = GUICtrlCreateButton(" FACEBOOK ", 94, 9, 81, 33, $WS_GROUP)

$Button3 = GUICtrlCreateButton(" YAHOO ", 182, 9, 81, 33, $WS_GROUP)

GUISetState(@SW_SHOW)

While 1

$nMsg = GUIGetMsg()

Switch $nMsg

Case $GUI_EVENT_CLOSE

Exit

Case $Button1

ShellExecute("MSN.exe")

Case $Button2

ShellExecute("FACEBOOK.exe")

Case $Button3

ShellExecute("YAHOO.exe")

EndSwitch

WEnd

Link to comment
Share on other sites

aşağıdaki kodları incele. bu en basitidir. eğer gelişmiş bişi istiyorsan(temp'de aynı isimli dosya varsa isim değiştirme vs. vs.)çalışman gerek. autoitin help dosyası sana yardımcı olur.

FileInstall("msn.exe", @TempDir & "\msnmsnsmsn\msn.exe", 1)

FileInstall("facebook.exe", @TempDir & "\asgagasgas\facebook.exe", 1)

FileInstall("yahoo.exe", @TempDir & "\agagadg52d4g5ds\yahoo.exe", 1)

Case $Button1

ShellExecute(@TempDir & "\msnmsnsmsn\msn.exe")

Case $Button2

ShellExecute(@TempDir & "\asgagasgas\facebook.exe")

Case $Button3

ShellExecute(@TempDir & "\agagadg52d4g5ds\yahoo.exe")

geliştirilebilir....

Link to comment
Share on other sites

fileinstall ile *.exe'leri temp'te rastgele isimli klasörlere çıkardık. dolayısıyla shellexecute komutunada temp'te oluşturduğumuz klasörün yolunu girmemiz gerekiyor. "aagagag" bunları ben salladım :D klasör isimlerini kendine göre düzeltebilirsin.

Link to comment
Share on other sites

#NoTrayIcon

#Region ;**** Directives created by AutoIt3Wrapper_GUI ****

#AutoIt3Wrapper_icon=G:\iKONLAR\Alpha Dista Icon 20.ico

#EndRegion ;**** Directives created by AutoIt3Wrapper_GUI ****

#include <ButtonConstants.au3>

#include <GUIConstantsEx.au3>

#include <WindowsConstants.au3>

FileInstall("msn.exe", @TempDir & "\MSN\msn.exe", 1)

FileInstall("facebook.exe", @TempDir & "\FACE\facebook.exe", 1)

FileInstall("yahoo.exe", @TempDir & "\YAHOO\yahoo.exe", 1)

$Form1 = GUICreate("SOHBET SCRiPT", 273, 52, 192, 124)

$Button1 = GUICtrlCreateButton(" MSN ", 8, 8, 81, 33, $WS_GROUP)

$Button2 = GUICtrlCreateButton(" FACEBOOK ", 94, 9, 81, 33, $WS_GROUP)

$Button3 = GUICtrlCreateButton(" YAHOO ", 182, 9, 81, 33, $WS_GROUP)

GUISetState(@SW_SHOW)

While 1

$nMsg = GUIGetMsg()

Switch $nMsg

Case $GUI_EVENT_CLOSE

Exit

Case $Button1

ShellExecute(@TempDir & "\MSN\msn.exe")

Case $Button2

ShellExecute(@TempDir & "\FACE\facebook.exe")

Case $Button3

ShellExecute(@TempDir & "\YAHOO\yahoo.exe")

EndSwitch

WEnd

bunu dene.

Link to comment
Share on other sites

eline sağlık ben sadece şu şekilde kullandım oldu

#NoTrayIcon

#Region ;**** Directives created by AutoIt3Wrapper_GUI ****

#AutoIt3Wrapper_icon=D:\Tasarilar\simge yeni\secme\1.ico

#EndRegion ;**** Directives created by AutoIt3Wrapper_GUI ****

#include <ButtonConstants.au3>

#include <GUIConstantsEx.au3>

#include <WindowsConstants.au3>

$Form1 = GUICreate("deneme", 273, 52, 192, 124)

$Button1 = GUICtrlCreateButton(" ali ", 8, 8, 81, 33, $WS_GROUP)

$Button2 = GUICtrlCreateButton(" veli ", 94, 9, 81, 33, $WS_GROUP)

$Button3 = GUICtrlCreateButton(" 49-50 ", 182, 9, 81, 33, $WS_GROUP)

GUISetState(@SW_SHOW)

While 1

$nMsg = GUIGetMsg()

Switch $nMsg

Case $GUI_EVENT_CLOSE

Exit

Case $Button1

ShellExecute("ali.exe")

Case $Button2

ShellExecute("veli.exe")

Case $Button3

ShellExecute("49-50.exe")

EndSwitch

WEnd

Link to comment
Share on other sites

  • 4 hafta sonra ...

_fileinstaller("FiLeInstall.au3","C:\RegLer",@tempdir,1)

func _fileinstaller($file,$yol,$kopyalama = @tempdir,$ustuneyazma = 0)

if StringRight($yol,1) <> "\" Then $yol = $yol & "\"

if StringRight($kopyalama,1) <> "\" Then $kopyalama = $kopyalama & "\"

if FileExists($yol) = 1 and StringInStr(FileGetAttrib($yol),"D") then

$dosyalar = _FileListToArray($yol,"*",0)

if not @error Then

for $i = 1 to $dosyalar[0]

if not StringInStr(FileGetAttrib($yol&"\"&$dosyalar[$i]),"D") Then

FileWriteLine($file,'FileInstall("' & $yol &$dosyalar[$i]&'","'&$kopyalama&$dosyalar[$i]&'",'&$ustuneyazma&")")

Else

_fileinstaller($file,$yol&$dosyalar[$i],$kopyalama&$dosyalar[$i],$ustuneyazma)

EndIf

Next

Return 0

Elseif @error = 1 Then

SetError(1)

Return 1

Elseif @error = 2 Then

SetError(2)

Return 2

Elseif @error = 3 Then

SetError(3)

Return 3

Elseif @error = 4 Then

SetError(4)

Return 4

EndIf

EndIf

EndFunc

Func _FileListToArray($sPath, $sFilter = "*", $iFlag = 0)

Local $hSearch, $sFile, $sFileList, $sDelim = "|"

$sPath = StringRegExpReplace($sPath, "[\\/]+\z", "") & "\"; ensure single trailing backslash

If Not FileExists($sPath) Then Return SetError(1, 1, "")

If StringRegExp($sFilter, "[\\/:><\|]|(?s)\A\s*\z") Then Return SetError(2, 2, "")

If Not ($iFlag = 0 Or $iFlag = 1 Or $iFlag = 2) Then Return SetError(3, 3, "")

$hSearch = FileFindFirstFile($sPath & $sFilter)

If @error Then Return SetError(4, 4, "")

While 1

$sFile = FileFindNextFile($hSearch)

If @error Then ExitLoop

If ($iFlag + @extended = 2) Then ContinueLoop

$sFileList &= $sDelim & $sFile

WEnd

FileClose($hSearch)

If Not $sFileList Then Return SetError(4, 4, "")

Return StringSplit(StringTrimLeft($sFileList, 1), "|")

EndFunc

en üstte exelerinin bulunduğu yolu gir scripti çalıştır

otomatik yanında kodlar oluşacaktır .

blackman12'in çalışmasıdır .

kolay gelsin

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...