|Visual C++ Code Samples And Utilities
Changing the screen brightness programmingly - By using the Gamma Ramp API
Some video cards allows you to programmingly modify the Gamma Ramp values.
You can use this feature to change the brightness of the entire screen.
Preventing application crash by using exception handling mechanism
When a program does something wrong, for example, reading from invalid memory address,
the operating system displays a "crash" window with information about the problem that caused the exception,
and terminates the application. This sample project demonstrates how to avoid
this kind of crashes, display your own exception information window,
and allow the user to continue running the application after the exception occurred.
Moving items up and down in a ListView control.
In some occasions, you might want to allow the user the change the order of items in the ListView, by moving the selected items up and down. In the API of ListView control, there is no support for swapping between 2 items. The only way to do that, is by manually swapping all data of the items, including the lParam value and all columns !
Displaying 'Browse Folders' dialog with the default folder selected.
The 'Browse For Folder' dialog allows the user to select a folder from all available local drives and network resources.
This code snippet demonstrate how to display this dialog-box.
Displaying the 'Properties' of a file or folder.
When you select a file or folder in Explorer window, and choose 'Properties' from the menu, you get the properties window that contains some essential information about the file: The size of file, created date, modified date, attributes, and so on.
It's possible to display this properties window programmatically, by using the ShellExecuteEx API function.
Enumerating Windows credentials with CredEnumerate function
This code sample enumerates all credentials of the current logged on user,
and dump them into the standard output.
|Utilities With Full Source Code
The ExeInfo utility shows general information about executable files (*.exe), dynamic-link libraries (*.dll),
ocx files, and drivers files.
AtNow is a command-line utility that schedules programs and commands to run in the near future.
WinExplorer is a utility that shows all system's windows in hierarchical
For every window in the hierarchy, you can view its properties,
like handle, class name, caption, size, position and more. You can also modify
some properties, like Caption and Visible/Enable.
Return back to NirSoft Freeware Utilities