I have an older laptop that I use for small tasks, but it no longer has sufficient resources to run the demands of ever-growing OS and browser bloat. If the RAM of your computer is not sufficient, both the performance and the speed will be affected. On Windows 10, you’re allowed to use your hard drive as RAM. Shout out to minitool.com to provide clear instructions as to how you how to increase the RAM by using hard disk on Windows 10.
Category: Windows
.NET: Debugging A Windows Service
1. Navigate to the windows service project.
2. From toolbar, select Project –> Properties
3. Set “Output type:” dropdown to “Console Application”
4. Open Program.cs, locate Main method, and add the following:
static void Main(string[] args)
{
//to test and debug
if (Environment.UserInteractive)
{
YourWinService serviceHb = new YourWinService(args);
serviceHb.TestStartupAndStop(args);
}
else
{
var servicesToRun = new ServiceBase[]
{
new YourWinService(args)
};
ServiceBase.Run(servicesToRun);
}
}
5. Navigate to your service code and add the following method:
internal void TestStartupAndStop(string[] args)
{
this.OnStart(args);
Console.ReadLine();
this.OnStop();
}
6. Set breakpoints and run as console app.
Windows 7: Fatal Error: Installation ended prematurely because of an error.
Sometimes I receive the following error when trying to install an application in Vista or Windows 7. The installation seems to go through as expected but then will roll back and throw the following error (note that sometimes this error presents as “Error 2869”):
Fatal Error: Installation ended prematurely because of an error.
Apparently, this occurs when an application attempts to install with the 32-bit version of InstallUtil.exe but actually needs to use the 64-bit version of InstallUtil.exe.
Sometimes, the fix is as simple as running your installation as “Administrator.” The rest of the time, it seems as if you have to somehow point your installation to use the 64-bit version.
First, navigate to C:WindowsMicrosoft.NETFramework. From here you might see the different versions of the framework installed on your machine. There should be a version of InstallUtil.exe in each folder.
Your installation is probably trying to use 2.0.* instead of 3.0/3.5/4.0.
Work-around:
1. Locate the path to your installation program (ie, C:Program FilesMyInstallationFolderMyInstall.exe)
2. Open a command prompt window as administrator
3. Navigate to the version of InstallUtil.exe you want to use (ie, C:WindowsMicrosoft.NETFrameworkv4.0.30319)
4. Next, in the command prompt enter:
InstallUtil.exe “C:Program FilesMyInstallationFolderMyInstall.exe”
Your application should now install.
Windows 7: Customize Your Windows Theme
The default location for pre-installed Windows 7 themes are located at :
c:windowsresourcesthemes
Locations for other wallpaper theme files :
c:windowswebwallpaper
For themes that you have downloaded yourself :
C:Users{username}AppDataLocalMicrosoftWindowsThemes
To add a wallpaper to a theme: copy your own wallpaper image files to the folder that has the same theme name you would like to use. Then, enable the wallpaper in “Personalize –> Desktop Background.”