kaan_karabey Posted April 21, 2013 Share Posted April 21, 2013 (edited) Bu konuyu nereye açaçağımı bilemedim o yüzden buraya açmaya karar verdim. programlamayla ilgili diye.yanlış yere açtıysam affola Arkadaslar ben proje ödevi için delphi 7 de program yazdım program açıldıgında capslock tusunu da aktif etmesini istiyorum.CapsLocku Açma Ayarını nasıl yapacam acaba yardım edebilecek biri var mı? Edited April 21, 2013 by kaan_karabey Quote Link to comment Share on other sites More sharing options...
Editor pairs Posted April 21, 2013 Editor Share Posted April 21, 2013 Sorunu yazılım bolumune acmalisin Quote Link to comment Share on other sites More sharing options...
reyiz Posted April 21, 2013 Share Posted April 21, 2013 SendKeys"{CAPSLOCK}" Dener misiniz? Quote Link to comment Share on other sites More sharing options...
reyiz Posted April 21, 2013 Share Posted April 21, 2013 Bir de böyle bir kod buldum kendinize göre uyarlayabilirsiniz. Eğer capslock kapalı ise açılmasını sağlayabilirsiniz: procedure ToggleNumLock; var KeyState: TKeyboardState; begin //note: Use VK_CAPITAL for Caps Lock GetKeyboardState(KeyState) ; //simulate key events (down + up) if (KeyState[VK_NUMLOCK] = 0) then begin Keybd_Event(VK_NUMLOCK, 1, KEYEVENTF_EXTENDEDKEY or 0, 0) ; Keybd_Event(VK_NUMLOCK, 1, KEYEVENTF_EXTENDEDKEY or KEYEVENTF_KEYUP, 0) ; end else begin Keybd_Event(VK_NUMLOCK, 0, KEYEVENTF_EXTENDEDKEY or 0, 0) ; Keybd_Event(VK_NUMLOCK, 0, KEYEVENTF_EXTENDEDKEY or KEYEVENTF_KEYUP, 0) ; end; end; Quote Link to comment Share on other sites More sharing options...
NoobAccountant Posted April 21, 2013 Share Posted April 21, 2013 Bu konu "AutoPlay Media Studio" forumundan "Yazılım" forumuna taşınmıştır. Quote Link to comment Share on other sites More sharing options...
kaan_karabey Posted April 21, 2013 Author Share Posted April 21, 2013 Bir de böyle bir kod buldum kendinize göre uyarlayabilirsiniz. Eğer capslock kapalı ise açılmasını sağlayabilirsiniz: procedure ToggleNumLock; var KeyState: TKeyboardState; begin //note: Use VK_CAPITAL for Caps Lock GetKeyboardState(KeyState) ; //simulate key events (down + up) if (KeyState[VK_NUMLOCK] = 0) then begin Keybd_Event(VK_NUMLOCK, 1, KEYEVENTF_EXTENDEDKEY or 0, 0) ; Keybd_Event(VK_NUMLOCK, 1, KEYEVENTF_EXTENDEDKEY or KEYEVENTF_KEYUP, 0) ; end else begin Keybd_Event(VK_NUMLOCK, 0, KEYEVENTF_EXTENDEDKEY or 0, 0) ; Keybd_Event(VK_NUMLOCK, 0, KEYEVENTF_EXTENDEDKEY or KEYEVENTF_KEYUP, 0) ; end; end; bunu neresine yazacam anlamadım :( Quote Link to comment Share on other sites More sharing options...
SimpsoN_Bart Posted April 21, 2013 Share Posted April 21, 2013 Orası sana kalmış bir durum ister load olayına ister buton koyun onun olayına yazabilirsin.Buton için. procedure TForm1.Button1Click(Sender: TObject) ; begin ... end; Quote Link to comment Share on other sites More sharing options...
kaan_karabey Posted April 21, 2013 Author Share Posted April 21, 2013 Orası sana kalmış bir durum ister load olayına ister buton koyun onun olayına yazabilirsin.Buton için. procedure TForm1.Button1Click(Sender: TObject) ; begin ... end; öyle diyorsunda ben program çalıstıgı anda otomatik olarak capslock kapalı ise acmasını istiyorum.butonla falan değil. Quote Link to comment Share on other sites More sharing options...
Editor pairs Posted April 21, 2013 Editor Share Posted April 21, 2013 Forum un On Create Eventi ne Quote Link to comment Share on other sites More sharing options...
SimpsoN_Bart Posted April 21, 2013 Share Posted April 21, 2013 (edited) E o zaman dediğim gibi yapacaksın reyizin kodlarını on create (load) eventine yazacaksın bu kadar. Edited April 21, 2013 by SimpsoN_Bart 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.