Jump to content

Scripte Çalışıp .exe De Çalışmama Sorunu


byMaPa
 Share

Recommended Posts

If Not FileExists(@WindowsDir & "\System32\Drivers\a.sys") Then
	If @OSArch = "X86" Then
		ShellExecuteWait(@TempDir & "\x86.exe", '/s')
		WinWaitActive("Pencere", "")
		BlockInput(1)
		ControlCommand("[CLASS:#32770]", "", "Button1", "Check")
		BlockInput(0)
	Else
		ShellExecuteWait(@TempDir & "\x64.exe", 'add')
		WinWaitActive("Pencere", "")
		BlockInput(1)
		ControlCommand("[CLASS:#32770]", "", "Button1", "Check")
		BlockInput(0)
	EndIf
Else
	MsgBox(0x00000010, "Hata", "Zaten Kurulu", 5)
EndIf

Bu kod script üzerinde gayet iyi çalışıyor fakat exe haline getirince controlcommanad çalışmıyor yani düğmeye basmıyor. Hatta daha doğrusu winwaitactive çalışmıyor. yani gelen pencereyi tanımıyor. ama script üzerinde deneyince pencereyi tanıyor.

Edited by byMaPa
Link to comment
Share on other sites

Temp klasöründe dosyanın olup olmadığından emin olun. Scriptte başka sorun yok.

hepsi olur ama shellexecute hiç olmaz. çünkü direk kurulmasını beklemeden diğer satırlara geçiyor ve bilgisayarda deepfreeze var yani temp klasöründe aynı isimde dosya olması imkansız.

Link to comment
Share on other sites

Program kurulduktan sonra açılan pencereye mi tıklatacaksın, yoksa yükleme esnasında kurulum ekranına mı tıklatacaksın ?

parametre ile kuruyorum ve kurulumdan sonra kurulum tamamlandı gibisinden pencere geliyor. o pencereyi kapatmak amacım

Link to comment
Share on other sites

O zaman ShellExecuteWait kullanamazsın, çünkü kodlar kurulum tamamlandı penceresi görünüp kapandıktan sonra devreye girer ve hiçbir anlamı olmaz. Traytip'i kapatmaya çalışıyorsun herhalde, nasıl kapanır bilemiyorum.

Link to comment
Share on other sites

O zaman ShellExecuteWait kullanamazsın, çünkü kodlar kurulum tamamlandı penceresi görünüp kapandıktan sonra devreye girer ve hiçbir anlamı olmaz. Traytip'i kapatmaya çalışıyorsun herhalde, nasıl kapanır bilemiyorum.

aynen sorunu şimdi anladım. shellexecute diyip winwait yapsam pencereyi bekler mi acaba bi de öyle deniyim

Link to comment
Share on other sites

#RequireAdmin

FileInstall("SPTDinst-x64.exe", @TempDir & "\SPTDinst-x64.exe", 1)
FileInstall("SPTDinst-x86.exe", @TempDir & "\SPTDinst-x86.exe", 1)

If Not FileExists(@WindowsDir & "\System32\Drivers\sptd.sys") Then
	If @OSArch = "X86" Then
		ShellExecute(@TempDir & "\SPTDinst-x86.exe", 'add')
		WinWait("SPTD setup V1.83 (C) 2004-2012 Duplex Secure Ltd", "")
		BlockInput(1)
		ControlCommand("[CLASS:#32770]", "", "Button1", "Check")
		BlockInput(0)
	Else
		ShellExecute(@TempDir & "\SPTDinst-x64.exe", 'add')
		WinWait("SPTD setup V1.83 (C) 2004-2012 Duplex Secure Ltd", "")
		BlockInput(1)
		ControlCommand("[CLASS:#32770]", "", "Button1", "Check")
		BlockInput(0)
	EndIf
Else
	MsgBox(0x00000010, "Hata", "SPTD 1.83 Bilgisayarınızda Zaten Kurulu", 5)
EndIf

FileDelete(@TempDir & "\SPTDinst-x86.exe")
FileDelete(@TempDir & "\SPTDinst-x64.exe")

Exit

autoit bilgim fazla yok ancak bu kadar yazabildim

Edited by byMaPa
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...