ClapTonApp Posted January 31, 2014 Share Posted January 31, 2014 Merhaba arkadaşlar,autoitte msgboxdaki yazıları değiştireceğim,1. butona basınca şu komut,2. butona basınca şu komut işleyecek.Bilmem anlatabildim mi :) , şimdiden teşekkür ederim herkese,iyi forumlar. Quote Link to comment Share on other sites More sharing options...
mesale0077 Posted January 31, 2014 Share Posted January 31, 2014 http://www.autoitscript.com/forum/topic/109096-extended-message-box-new-version-11-aug13/ örneğini inceleyin Quote Link to comment Share on other sites More sharing options...
ClapTonApp Posted January 31, 2014 Author Share Posted January 31, 2014 http://www.autoitscript.com/forum/topic/109096-extended-message-box-new-version-11-aug13/ örneğini inceleyin Teşekkürler,fakat çok karışık,bir şey anlamadım :( Quote Link to comment Share on other sites More sharing options...
mesale0077 Posted January 31, 2014 Share Posted January 31, 2014 basit guı oluştur msgbox gibi oda işini görür ,autoit ile kod bilginiz anladığım kadarıyla az peki ben kodları versem editleme yapabilecekmisiniz :D küçümseme manasında demedim ,nasıl editleme yapacağınız konusunda size nasıl yardımcı olabilirim onu düşündüm . Quote Link to comment Share on other sites More sharing options...
ClapTonApp Posted January 31, 2014 Author Share Posted January 31, 2014 (edited) basit guı oluştur msgbox gibi oda işini görür ,autoit ile kod bilginiz anladığım kadarıyla az peki ben kodları versem editleme yapabilecekmisiniz :D küçümseme manasında demedim ,nasıl editleme yapacağınız konusunda size nasıl yardımcı olabilirim onu düşündüm . Aslında az değil,o manada anlamadım,ne demek :D ,editlerim bir şekilde,şimdiden teşekkür ediyorum :D Edited January 31, 2014 by ClapTonApp Quote Link to comment Share on other sites More sharing options...
mesale0077 Posted January 31, 2014 Share Posted January 31, 2014 (edited) $MsgBoxValue = _MsgBoxChangeButtons(35, 'This is my msgbox', 'This' & @CRLF & 'Should' & @CRLF & 'Work', 'ReBoot', 'Continue', 'Cancel', 20, 1) If $MsgBoxValue = 6 Then MsgBox(0, 'Clicked', 'You clicked the ReBoot Button') If $MsgBoxValue = -1 Then MsgBox(0, 'Time out', 'The time is out, the default button was pressed') Func _MsgBoxChangeButtons($iFlag, $sTitle, $sText, $sButton1, $sButton2 = '', $sButton3 = '', $iMBTimeOut = 0, $DefButtonTO = 1) Local $MBFile = FileOpen(@TempDir & '\MiscMMB.txt', 2) Local $MBLine = '#NoTrayIcon' & @CRLF $MBLine &= 'While Not WinExists("' & $sTitle & '")' & @CRLF $MBLine &= ' Sleep(10)' & @CRLF $MBLine &= 'WEnd' & @CRLF $MBLine &= 'ControlSetText("' & $sTitle & '", "", "Button1", "' & $sButton1 & '")' & @CRLF If $sButton2 <> '' Then $MBLine &= 'ControlSetText("' & $sTitle & '", "", "Button2", "' & $sButton2 & '")' & @CRLF If $sButton3 <> '' Then $MBLine &= 'ControlSetText("' & $sTitle & '", "", "Button3", "' & $sButton3 & '")' & @CRLF Switch $DefButtonTO Case 1 $ButtonToSet = $sButton1 Case 2 $ButtonToSet = $sButton2 Case 3 $ButtonToSet = $sButton3 Case Else $ButtonToSet = $sButton1 EndSwitch If $iMBTimeOut > 0 Then $MBLine &= '$TimerInit = TimerInit()' & @CRLF & 'While (TimerDiff($TimerInit) / 1000) < ' & $iMBTimeOut & _ @CRLF & ' ControlSetText("' & $sTitle & '", "", "Button' & $DefButtonTO & '", "' & $ButtonToSet & _ ' (" & ' & $iMBTimeOut & ' - Round(TimerDiff($TimerInit)/1000) & ")")' & @CRLF & _ ' If Not WinExists("' & $sTitle & '") Then ExitLoop' & @CRLF & 'WEnd' EndIf FileWrite(@TempDir & '\MiscMMB.txt', $MBLine) $MBPID1 = Run(@AutoItExe & ' /AutoIt3ExecuteScript ' & @TempDir & '\MiscMMB.txt') $MBBox = MsgBox($iFlag, $sTitle, $sText, $iMBTimeOut) FileClose($MBFile) Do FileDelete(@TempDir & '\MiscMMB.txt') Until Not FileExists(@TempDir & '\MiscMMB.txt') Return $MBBox EndFunc http://www.autoitscript.com/forum/topic/27485-msgbox-customized-anwsers/page-2 http://www.autoitscript.com/forum/topic/92903-advanced-message-box-udf-lib/ konularını inceleyiniz Edited January 31, 2014 by mesale0077 Quote Link to comment Share on other sites More sharing options...
ClapTonApp Posted January 31, 2014 Author Share Posted January 31, 2014 (edited) $MsgBoxValue = _MsgBoxChangeButtons(35, 'This is my msgbox', 'This' & @CRLF & 'Should' & @CRLF & 'Work', 'ReBoot', 'Continue', 'Cancel', 20, 1) If $MsgBoxValue = 6 Then MsgBox(0, 'Clicked', 'You clicked the ReBoot Button') If $MsgBoxValue = -1 Then MsgBox(0, 'Time out', 'The time is out, the default button was pressed') Func _MsgBoxChangeButtons($iFlag, $sTitle, $sText, $sButton1, $sButton2 = '', $sButton3 = '', $iMBTimeOut = 0, $DefButtonTO = 1) Local $MBFile = FileOpen(@TempDir & '\MiscMMB.txt', 2) Local $MBLine = '#NoTrayIcon' & @CRLF $MBLine &= 'While Not WinExists("' & $sTitle & '")' & @CRLF $MBLine &= ' Sleep(10)' & @CRLF $MBLine &= 'WEnd' & @CRLF $MBLine &= 'ControlSetText("' & $sTitle & '", "", "Button1", "' & $sButton1 & '")' & @CRLF If $sButton2 <> '' Then $MBLine &= 'ControlSetText("' & $sTitle & '", "", "Button2", "' & $sButton2 & '")' & @CRLF If $sButton3 <> '' Then $MBLine &= 'ControlSetText("' & $sTitle & '", "", "Button3", "' & $sButton3 & '")' & @CRLF Switch $DefButtonTO Case 1 $ButtonToSet = $sButton1 Case 2 $ButtonToSet = $sButton2 Case 3 $ButtonToSet = $sButton3 Case Else $ButtonToSet = $sButton1 EndSwitch If $iMBTimeOut > 0 Then $MBLine &= '$TimerInit = TimerInit()' & @CRLF & 'While (TimerDiff($TimerInit) / 1000) < ' & $iMBTimeOut & _ @CRLF & ' ControlSetText("' & $sTitle & '", "", "Button' & $DefButtonTO & '", "' & $ButtonToSet & _ ' (" & ' & $iMBTimeOut & ' - Round(TimerDiff($TimerInit)/1000) & ")")' & @CRLF & _ ' If Not WinExists("' & $sTitle & '") Then ExitLoop' & @CRLF & 'WEnd' EndIf FileWrite(@TempDir & '\MiscMMB.txt', $MBLine) $MBPID1 = Run(@AutoItExe & ' /AutoIt3ExecuteScript ' & @TempDir & '\MiscMMB.txt') $MBBox = MsgBox($iFlag, $sTitle, $sText, $iMBTimeOut) FileClose($MBFile) Do FileDelete(@TempDir & '\MiscMMB.txt') Until Not FileExists(@TempDir & '\MiscMMB.txt') Return $MBBox EndFunc Düzenledim,msgbox 35 yerine 36 kullanıyorum cancele ihtiyaç yok :D , çok teşekkür ederim. Edited January 31, 2014 by ClapTonApp Quote Link to comment Share on other sites More sharing options...
mesale0077 Posted January 31, 2014 Share Posted January 31, 2014 Düzenledim,msgbox 35 yerine 36 kullanıyorum cancele ihtiyaç yok :D , çok teşekkür ederim. , çok teşekkür ederim. yerine beğen buttonuna basın teşekkür etmek yasak ondan yani :D konuyu çözüm sağladığımıza ve beğendiğinize sevindim Quote Link to comment Share on other sites More sharing options...
Recommended Posts
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.