@bobnoordam

Author: bobnoordam

Monitoring the file system for changes

This code sample sets up a handler to monitor the c:\ disk for changes in any file’s size, and report those changes to the console. Imports System.IO Module Module1 ”’ <summary> ”’ Display the change events detected by the file system watcher on the console ”’ </summary> ”’ <param name=”sender”></param> ”’ <param name=”e”></param> ”’ <remarks></remarks> […]

Raising an event on a usercontrol, and subscribing to it from an ASPX page

This is a minimalistic demonstration on hooking into an event risen by a usercontrol. The main page subscribes to the event on the user control, and once the usercontrol raises a postback the event data is retrieved. User control code using System; using System.Collections.Generic; using System.Linq; using System.Web; using System.Web.UI; using System.Web.UI.WebControls; namespace UsercontrolEvents { […]

Collecting performance data from local and remote systems using C#

Performance data Perfmon is a well known tool to monitor performance data for your local and remote systems. This code snippet gives you a worker class that can be used to connect to local or remote perfmon / system performance data, and provide the resulting information stream to your c# application. Local and remote To […]

Enumerating available performance counters on local and remote systems using C#

Performance counters Perfmon, the well known tool for monitoring performance counters has a nice list of categories and counters for your system. But what if you want to access a counter from code ? Or even worse, want to check if a certain counter is available or not ? In the previous document Collecting performance […]

Autosizing screen stops on VmWare Workstation for your linux guest

Sympton:Your display no longer autosizes for your Linux guest, running under VmWare workstation. Cause: This seems to be caused by a race condition where the open-vm-tools try to activate before the graphic environment is available. Resolution: Edit the configuration file for open-vm-tools, by running nano sudo /etc/systemd/system/multi-user.target.wants/open-vm-tools.service And add the following lines in the UNIT […]

Next Page » « Previous Page