VBAutoRunRegistry is a VB.NET application designed to manage Windows startup registry entries for automatically launching applications. The project provides functionality for adding, removing, and managing registry keys to control the auto-run behavior of applications.
This solution leverages various interfaces and services to ensure that registry operations are performed in a modular, testable, and maintainable manner. It includes key components for handling user input, registry access, and service configuration using dependency injection principles.
- Registry Management: Create, read, update, and delete registry keys.
- Auto-Run Configuration: Automatically configure applications to run at Windows startup.
- Dependency Injection: Built with dependency injection principles to ensure modularity and maintainability.
- Error Handling: Exception handling for robust registry operations.
- Unit Testable: Designed with interfaces to support unit testing.
- VB.NET
- .NET Core/Framework
- Windows Registry API (via Microsoft.Win32 namespace)
- Dependency Injection
|-- Application
| |-- Interfaces
| | +-- IAppRunner.vb
| |-- AppRunner.vb
| |-- ProcessExitHandler.vb
| +-- ServiceConfigurator.vb
|
|-- RegistryManagement
| |-- Interfaces
| | |-- IApplicationRegistryManager.vb
| | |-- IRegistryHelper.vb
| | |-- IRegistryHive.vb
| | |-- IRegistryInstaller.vb
| | |-- IRegistryKey.vb
| | |-- IRegistryUninstaller.vb
| | +-- IStartupRegistryManager.vb
| |-- RegistryAccess
| | +-- RegistryMode.vb
| |-- ApplicationRegistryManager.vb
| |-- MicrosoftRegistryHive.vb
| |-- MicrosoftRegistryKey.vb
| |-- RegistryHelper.vb
| |-- RegistryInstaller.vb
| |-- RegistryUninstaller.vb
| +-- StartupRegistryManager.vb
|
|-- Utilities
| |-- Interfaces
| | |-- IUserInputChecker.vb
| | |-- IUserInputReader.vb
| | +-- IUserPrompter.vb
| |-- UserInputChecker.vb
| |-- UserInputReader.vb
| +-- UserPrompter.vb
|
|-- GlobalAttribute.vb
+-- Program.vb
- .NET SDK: Ensure that the .NET SDK (Core or Framework) is installed on your machine. You can download it here.
- Visual Studio: While any IDE can be used, the project is optimized for Visual Studio 2019/2022.
- Clone the repository:
git clone https://github.com/YourUsername/VBAutoRunRegistry.git cd VBAutoRunRegistry
- Open the solution in Visual Studio and restore the NuGet packages.
To run the application, execute the following steps:
- Compile the solution in Visual Studio.
- Ensure you have sufficient privileges to modify the registry on your machine.
- Run the executable or use the debugger to step through and observe registry changes.
Special thanks to AtmaWeapon(xtremevbtalk 2009) for invaluable guidance in learning about registry handling in VB.NET and emphasizing the importance of programming principles over mere code replication.