Start The asp net counters are not updating

The asp net counters are not updating

access HKLM\SYSTEM\Current Control Set\Services) as noted in the KB. If you want to understand the CAS policy, this is a nice article: Understanding .

I've been trying to follow exactly what it says in my textbook, but to no avail.

Now, my problem is that I'm currently attempting to make a page counter to keep track of how many times each page has been accessed, then display each value on a new page.

The CAS policy was/is a mechanism to determine if the executing code has permission for an operation (often on resource, e.g.

filesystem or performance counters) and if it didn't, the Security Exeption was thrown.

Here is the C# Counter code which is the same for all pages: When I try to run it, I get a "Null Reference Exception was unhandled by user code, Object reference not set to an instance of an object." Error. EDIT #1 Okay, Thanks to Hexxangonal, the counter is now working.

However, my Counter Page is now counting it self by 2 times.

From there I added the user to the power users group and continued on my way without issue.

It was from an unrelated issue that I later discovered that "Power User" no longer has any permissions beyond Vista and that let me back to that same article: Fortunately, given these alternatives, it turns out that the permission set required to update performance counters is much smaller than running as an Administrator or Power User.

However, when I go to the performance monitor, there's not a choice of ASP. There are also a bunch of other performance counter choices.

The websites use 2 application pools, each which is using v4.0 of the . If I look in the task manager, i see two w3wp.exe's running, each a IIS worker process. I added app Domain Resource Montoring to the aspnet.config file, but that didn't help.

The database is a nice option simply because there can be a metric ton of events raised depending on your configuration.