- Kayıt
- 19 Ekim 2009
- Mesajlar
- 10.451
- Beğeniler
- 97
- Takımı
- Galatasaray
Sizler İçin Arşivimden Seçerek Çıkarttığım Ufak Ama İşe Yarar Kod Parçacıkları ;
Başlık Çubuğu Olmadan Formu Taşıma
Başlangıçta Form Ekran Ortasında
İşlemciyi Göster
Programınız Üst Üste Çalışmaz
Saat & Tarih
Araçlar : 1 adet Timer , 2 adet Label
Herhangi Bir Siteye Giriş Komutu
Visual Basic 6 İçindir.
Saygılar,Maybe
Başlık Çubuğu Olmadan Formu Taşıma
Private Declare Function SendMessage Lib "user32" Alias "SendMessageA" _
(ByVal hwnd As Long, ByVal wMsg As Long, _
ByVal wParam As Integer, ByVal IParam As Long) As Long
Private Declare Sub ReleaseCapture Lib "user32" ()
Private Const WM_NCLBUTTONDOWN = &HA1
Private Const HTCAPTION = 2
Private Sub Formu_Taşı(sForm As Form)
ReleaseCapture
Call SendMessage(sForm.hwnd, WM_NCLBUTTONDOWN, HTCAPTION, 0)
End Sub
Private Sub Form_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
'Sol Fare tuşuna tıklayarak formu taşıyabilirsiniz.
If Button = 1 Then Formu_Taşı Me
End Sub
(ByVal hwnd As Long, ByVal wMsg As Long, _
ByVal wParam As Integer, ByVal IParam As Long) As Long
Private Declare Sub ReleaseCapture Lib "user32" ()
Private Const WM_NCLBUTTONDOWN = &HA1
Private Const HTCAPTION = 2
Private Sub Formu_Taşı(sForm As Form)
ReleaseCapture
Call SendMessage(sForm.hwnd, WM_NCLBUTTONDOWN, HTCAPTION, 0)
End Sub
Private Sub Form_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
'Sol Fare tuşuna tıklayarak formu taşıyabilirsiniz.
If Button = 1 Then Formu_Taşı Me
End Sub
Başlangıçta Form Ekran Ortasında
move(screen.width-width)/2, (screen.height-height)/2
İşlemciyi Göster
Set Reg = CreateObject("Wscript.Shell")
MsgBox "CPU " & Reg.RegRead("HKEY_LOCAL_MACHINE\Hardware\Description\System\CentralProcessor\0\ProcessorNameString")
MsgBox "CPU " & Reg.RegRead("HKEY_LOCAL_MACHINE\Hardware\Description\System\CentralProcessor\0\ProcessorNameString")
Programınız Üst Üste Çalışmaz
Form_Load Kısmına
If App.PrevInstance Then
MsgBox "Program zaten aktif", vbInformation
End
end if
If App.PrevInstance Then
MsgBox "Program zaten aktif", vbInformation
End
end if
Saat & Tarih
Araçlar : 1 adet Timer , 2 adet Label
Private Sub Form_Load()
Timer1.Interval = 100
End Sub
Private Sub Timer1_Timer()
Label1 = Date
Label2 = Time
End Sub
Timer1.Interval = 100
End Sub
Private Sub Timer1_Timer()
Label1 = Date
Label2 = Time
End Sub
Herhangi Bir Siteye Giriş Komutu
Shell "explorer.exe http://www.extraloob.com"
Visual Basic 6 İçindir.
Saygılar,Maybe