MasterTR Posted August 16, 2011 Share Posted August 16, 2011 (edited) [code]Run("winword") WinWait("[CLASS:OpusApp]") WinActivate("[CLASS:OpusApp]") ControlSend("[CLASS:OpusApp]", "", "_WwG1", "Merhaba Master TR")[/code] [b]Bunu çalıştırda winword yaziyorum office çalışıyor Run komutunun içine yazıp çağırdığımda çalışmıyor.[/b] Edited August 18, 2011 by MasterTR Quote Link to comment Share on other sites More sharing options...
MostWanted Posted August 16, 2011 Share Posted August 16, 2011 (edited) [codebox]#include <ButtonConstants.au3> #include <EditConstants.au3> #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> #Region ### START Koda GUI section ### Form=C:\Users\MERT\Desktop\Form1.kxf $Form1 = GUICreate("Form1", 343, 274, 319, 494) $MenuItem1 = GUICtrlCreateMenu("Dosya") $MenuItem3 = GUICtrlCreateMenuItem("Çıkış", $MenuItem1) $MenuItem2 = GUICtrlCreateMenu("MasterTR") $Button1 = GUICtrlCreateButton("Button1", 104, 200, 115, 41) $Input1 = GUICtrlCreateInput("Input1", 112, 48, 105, 21) $Input2 = GUICtrlCreateInput("Input2", 112, 88, 105, 21) GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit Case $Button1 ; buraya yazacağın her şey butonun görevini belirtir. MsgBox(0, "Deneme", "Merhabe Dünya") ;gibi EndSwitch WEnd[/codebox] Case $form1 yanlış kullanılmış öyle bi kullanım yapamazsın bu arada. Edited August 17, 2011 by KintaRo codebox Quote Link to comment Share on other sites More sharing options...
MasterTR Posted August 17, 2011 Author Share Posted August 17, 2011 (edited) [b]hocam kullanımı program yaptı ben değil,Autoıt programını açtım tools menüsünden Forum Codda(Form Desiner) seçtim deneme amaçlı birşeyler ekledim ve F9 basarak codelarını alıp AutoIt Edit açarak içine yapıştırdım Derledim sonuç bu yanlış nasıl yapılmış bilmek isterim ki tekrar karşılaşmayayım,.[/b] [b]Anladım nasıl yapacağımı peki burda neden notepad çalışmadı.Görev verdim olmadı[/b] Edited August 17, 2011 by MasterTR Quote Link to comment Share on other sites More sharing options...
MasterTR Posted August 17, 2011 Author Share Posted August 17, 2011 (edited) Dediğin şekilde butona görev atadım Mesaj uyarısı çalışıyor WinWaitActive metodunu onunla kullanmaya çalıştığımda mesaj kutusuda devre dışı kaldı,çözemedim nerde hata yaptığımı metin belgesi açtırım onu yazdıracaktım. [codebox]#include <ButtonConstants.au3> #include <EditConstants.au3> #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> #Region ### START Koda GUI section ### Form=C:\Users\MERT\Desktop\Form1.kxf $Form1 = GUICreate("Form1", 343, 274, 319, 494) $MenuItem1 = GUICtrlCreateMenu("Dosya") $MenuItem3 = GUICtrlCreateMenuItem("Çıkış", $MenuItem1) $MenuItem2 = GUICtrlCreateMenu("MasterTR") $Button1 = GUICtrlCreateButton("Button1", 104, 200, 115, 41) $Input1 = GUICtrlCreateInput("Input1", 112, 48, 105, 21) $Input2 = GUICtrlCreateInput("Input2", 112, 88, 105, 21) GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit Case $Form1 Case $Button1 WinWaitActive("Untitled- Notepad", "Merhaba MasterTR ?") MsgBox(0, "My First Script!", "Hello World!") Case $Input2 EndSwitch WEnd [/codebox] Edited August 17, 2011 by KintaRo Quote Link to comment Share on other sites More sharing options...
blue_life Posted August 17, 2011 Share Posted August 17, 2011 WinWaitActive kullanırsan, ilgili pencerenin gelmesine bekleyeceğinden, programın haliyle çakılır. Butona basınca tam olarak ne yaptırmak istiyorsun? Quote Link to comment Share on other sites More sharing options...
MasterTR Posted August 17, 2011 Author Share Posted August 17, 2011 [b]Butonu tıkladığımda notepad açılsın Merhaba Master TR ? yazdıracaktım.[/b] Quote Link to comment Share on other sites More sharing options...
blue_life Posted August 17, 2011 Share Posted August 17, 2011 [codebox]#include <ButtonConstants.au3> #include <EditConstants.au3> #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> #Region ### START Koda GUI section ### Form=C:\Users\MERT\Desktop\Form1.kxf $Form1 = GUICreate("Form1", 343, 274, 319, 494) $MenuItem1 = GUICtrlCreateMenu("Dosya") $MenuItem3 = GUICtrlCreateMenuItem("Çıkış", $MenuItem1) $MenuItem2 = GUICtrlCreateMenu("MasterTR") $Button1 = GUICtrlCreateButton("Button1", 104, 200, 115, 41) $Input1 = GUICtrlCreateInput("Input1", 112, 48, 105, 21) $Input2 = GUICtrlCreateInput("Input2", 112, 88, 105, 21) GUISetState(@SW_SHOW) While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit Case $Form1 Case $Button1 Run("notepad") WinWait("[CLASS:Notepad]") WinActivate("[CLASS:Notepad]") ControlSend("[CLASS:Notepad]", "", "Edit1", "Merhaba Master TR") Case $Input2 EndSwitch WEnd[/codebox] Quote Link to comment Share on other sites More sharing options...
MasterTR Posted August 17, 2011 Author Share Posted August 17, 2011 [b]Help dosyasından yardım alarak ilerliyorum üstatda [code][CLASS:Notepad][/code] bu code ne anlama geliyor ? [/b] Quote Link to comment Share on other sites More sharing options...
KintaRo Posted August 17, 2011 Share Posted August 17, 2011 [warning][b]arkadaşlar uzun kodlarınızı codebox tagı içinde verelim, bu konudakileri ben düzelttim.[/b][/warning] Quote Link to comment Share on other sites More sharing options...
blue_life Posted August 17, 2011 Share Posted August 17, 2011 Bu pencerenin class bilgisidir. Au3Info programıyla ilgili pencerenin class bilgisini öğrenebilirsin. Quote Link to comment Share on other sites More sharing options...
radyofon Posted August 17, 2011 Share Posted August 17, 2011 [quote name='KintaRo' date='17 August 2011 - 11:27 ' timestamp='1313569674' post='1064635'] [warning][b]arkadaşlar uzun kodlarınızı codebox tagı içinde verelim, bu konudakileri ben düzelttim.[/b][/warning] [/quote] blue_life üstadın dediği gibi ya class bilgisini alırsın ya da açılan notepad penceresinin üzerinde yazan başlığa (title) göre işlem yaparsın. Başlığa göre yapacak olursan komut şu şekilde olmalı: [code] WinWaitActive("Notepad") [/code] Fakat diğer yöntem daha garantidir. Yani notepad aktif oluncaya kadar bekletmeye yarayan bir komut. Quote Link to comment Share on other sites More sharing options...
MasterTR Posted August 17, 2011 Author Share Posted August 17, 2011 (edited) Evet çok iyi anladım progmın class bilgisini öğrenmek için Info kullanacağız en güzel özelliği ise ınfo metin belgesinin içerigini Visible göstermesi sevdim bunu biraz tekrar ediyim [color="#0000FF"][b]KintaRo[/b][/color] [b]Üstat bundan sonra dikkat edeceğim uyarın için teşekkürler.[/b] [b]Biraz Çalışma Yapayım.[/b] Office Sorunu güncellendi postun başında. Edited August 18, 2011 by blackman12 Quote Link to comment Share on other sites More sharing options...
MostWanted Posted August 18, 2011 Share Posted August 18, 2011 (edited) Help dosyasında User Defined Functions Reference Word management kısmında bunların hiç birine gerek kalmadan işini halledebilirsin.Word belgelerini istediğin gibi yönetebilirsin. Edited August 18, 2011 by MostWanted 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.