Kod: Windows Reset 'Aşağıdakileri forma kopyalayın Private Declare Function ShutdownWindows Lib "user32" Alias "ExitWindowsEx" As Long Private Const EWX_LOGOFF = 0 Private Const EWX_SHUTDOWN = 1 Private Const EWX_REBOOT = 2 Private Const EWX_FORCE = 4 Const EWX_RESET = EWX_LOGOFF + EWX_FORCE + EWX_REBOOT Private Sub Form_Load Dim x As Integer x = ShutdownWindows(EWX_RESET, 0) End Sub Sadece windowsu kapatıp resetler shutdown olayı dos penceresinde de geçerlidir mesela sen başlat çalıştır a cmd yaz enterla ve shutdown yaz orada sana shutdown komutuyla neler yapabileceğini listeleyecektir Kod: Windows Temporary File Öğrenme 'Projenize 1 adet modül ekleyin 'Aşağıdakileri modüle kopyalayın Declare Function SendMessage Lib "User32" Alias "SendMessageA" As Long Declare Sub ReleaseCapture Lib "User32" Public Const WM_NCLBUTTONDOWN = &HA1 Public Const HTCAPTION = 2 'Aşağıdakileri forma kopyalayın Public Function GetTempPath Dim strFolder As String Dim lngResult As Long strFolder = String(MAX_PATH, 0) lngResult = GetTempPath If lngResult <> 0 Then GetTmpPath = Left(strFolder, InStr(strFolder, Chr(0)) - 1) Else GetTmpPath = "" End If End Function Private Sub Form_Load MsgBox GetTmpPath End Sub Kod: Windows Versiyonunu Öğrenmek 'Projenize 1 adet modül ekleyin 'Aşağıdakileri modüle kopyalayın Public Type OSVERSIONINFOEX dwOSVersionInfoSize As Long dwMajorVersion As Long dwMinorVersion As Long dwBuildNumber As Long dwPlatformId As Long szCSDVersion As String 128 End Type Public Const VER_PLATFORM_WIN32s = 0 Public Const VER_PLATFORM_WIN32_WINDOWS = 1 Public Const VER_PLATFORM_WIN32_NT = 2 Declare Function GetVersionEx Lib "kernel32" Alias "GetVersionExA" As Long 'Aşağıdakileri forma kopyalayın Public Function OSVersion As String Dim udtOSVersion As OSVERSIONINFOEX Dim lMajorVersion As Long Dim lMinorVersion As Long Dim lPlatformID As Long Dim sAns As String udtOSVersion. dwOSVersionInfoSize = Len GetVersionEx udtOSVersion lMajorVersion = udtOSVersion. dwMajorVersion lMinorVersion = udtOSVersion. dwMinorVersion lPlatformID = udtOSVersion. dwPlatformId Select Case lMajorVersion Case 5 sAns = "Windows 2000" Case 4 If lPlatformID = VER_PLATFORM_WIN32_NT Then sAns = "Windows NT 4.0" Else sAns = IIf(lMinorVersion = 0, "Windows 95", "Windows 98") End If Case 3 If lPlatformID = VER_PLATFORM_WIN32_NT Then sAns = "Windows NT 3. x" Else sAns = "Windows 3. x" End If Case Else sAns = "Unknown Windows Version" End Select OSVersion = sAns End Function Private Sub Form_Load MsgBox "Windows version Tesbit Edildi: " & OSVersion End Sub Kod: Windows System Directory Öğrenme 'Projenize 1 adet modül ekleyin 'Aşağıdakileri modüle kopyalayın Declare Function GetSystemDirectory Lib "kernel32" Alias "GetSystemDirectoryA" As Long 'Aşağıdakileri forma kopyalayın Private Sub Form_Load Dim S As String S = String(80, 0) Call GetSystemDirectory(S, 80) UserName = Left(S, InStr(S, Chr(0)) - 1) MsgBox End Sub Kod: Windows Shutdown 'Projenize 1 adet modül ekleyin 'Aşağıdakileri modüle kopyalayın Declare Function ExitWindowsEx Lib "user32" As Long 'Aşağıdakileri forma kopyalayın Private Sub Command1_Click ExitWindowsEx EWX_REBOOT, 0 Unload Me End Sub Kod: