|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
WindowsVersion - The version number of the operating system
|
Total Hit (1923) |
Just copy and paste the following code into Form code window
«code LangId=1»Private Type OSVERSIONINFO
dwOSVersionInfoSize As Long
dwMajorVersion As Long
dwMinorVersion As Long
dwBuildNumber As Long
dwPlatformId As Long
szCSDVersion As String * 128
End Type
Priva
....Read More |
Rating
|
|
|
|
How to find Time Zone information on current system ?
|
Total Hit (3291) |
The following code will extract the timezone information from your system. It includes three functions. One returns the current date/time in UTC (or ZULU or GMT) time, the next returns the offset of your time zone from GMT in minutes (divide by 60 to get hours), and the last returns the name of the
....Read More |
Rating
|
|
|
How to list all available timezones and change the timezone?
|
Total Hit (6677) |
It is sometimes necessary to programmatically change the time zone for the system where the application is running. This article demonstrates this technique.
The way to implement this effect is as follows:
Determine which time zone you would like to change to.
Find the key in the registry tha
....Read More |
Rating
|
|
|
|
Forcing Any Window to Show in the Taskbar
|
Total Hit (1974) |
VB provides a ShowInTaskBar property for forms which is meant to set whether a form is shown in the Alt-Tab sequence and the shell's task bar. However there are two limitations to this:
The property can't be set at run-time.
Erm, it doesn't work anyway.
Ok, it can work, but only when your form
....Read More |
Rating
|
|
|
Enumerating Windows Using the API
|
Total Hit (1871) |
Prior to VB5, it was impossible to use the enumeration methods provided in the Windows API without relying on a proprietary custom control. This was a problem if you wanted to find out all the Windows showing on the system, because the only reliable methods you can use to do this are through enumera
....Read More |
Rating
|
|
|
Responding to AppCommands
|
Total Hit (1713) |
The WM_APPCOMMAND message was added to Windows 2000 and ME to provide a mechanism to send the events from extended keys on newer keyboards to applications on the system. Extended keys are things like the back, forward and search button. This tip demonstrates how to intercept events from these keys i
....Read More |
Rating
|
|
|
Enumerating the Available Display Resolutions
|
Total Hit (1623) |
This routine uses Windows' EnumDisplaySettings API to retrieve all the available screen resolutions supported by the display. The results are populated to a ListView showing colour depths, resolutions and frequencies supported. In addition, the current system resolution is determined and flagged.
....Read More |
Rating
|
|
|
Changing the Display Resolution from Visual Basic
|
Total Hit (1160) |
This routine, like the ListView method in Enumerating the Available Display Resolutions, uses Windows' EnumDisplaySettings API to retrieve all the available screen resolutions supported by the display. Here, the results are used to create a "QuickRes-style menu", replete with the option of displayin
....Read More |
Rating
|
|
|
Using CopyFileEx and Callbacks as a File Backup Mechanism
|
Total Hit (1316) |
So that's how you do it!" This demo shows how to add a callback to the CopyFileEx API that returns the progress of a copying routine. But there is a catch ... CopyFileEx is only available on real operating systems - AKA Windows NT.
|
Rating
|
|
|
Enumerating and Restoring Windows Using Callbacks
|
Total Hit (1397) |
Here's a quick routine that will enumerate all top-level windows and provide a Restore feature to restore the app to the foreground. Once again the venerable EnumWindows API forms the base for this demo, with supporting roles going to GetWindowPlacement, BringWindowToTop, and friends.
....Read More |
Rating
|
|
|
Enumerating Windows Using Callbacks
|
Total Hit (1214) |
Windows offers VB programmers the 'EnumXXX' APIs providing callback data for specific tasks.
This page demonstrates using the EnumWindows() API to enumerate all windows on the system, and populate a listbox with their class name, hwnd and window text if available.
....Read More |
Rating
|
|
|
EnumWindows and EnumChildWindows Callbacks
|
Total Hit (1592) |
Many Windows' Enum APIs provide callback data for specific tasks.
This project demonstrates using both EnumWindows and EnumChildWindows APIs and their respective EnumWindowProc and EnumChildProc callbacks. The main form in the demo enumerates all top-level windows on the system populating ListView
....Read More |
Rating
|
|