473,404 Members | 2,187 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,404 software developers and data experts.

How to raise a WebBaseErrorEvent or WebManagementEvent

Hi,

We are using ASP.NET 2.0 health and monitoring provider.
I know that the platform raises events automatically.

I just wanted to know how can we raise them in C# code? I am trying to raise
WebBaseErrorEvent or WebManagementEvent.

Thank you,
Max
Oct 24 '07 #1
2 2764

(new WebRequestEvent("my message",
null,
WebEventCodes.WebExtendedbase +1)).Raise();

-- bruce (sqlworkcom)

Max2006 wrote:
Hi,

We are using ASP.NET 2.0 health and monitoring provider.
I know that the platform raises events automatically.

I just wanted to know how can we raise them in C# code? I am trying to raise
WebBaseErrorEvent or WebManagementEvent.

Thank you,
Max

Oct 24 '07 #2
Thanks for bruce's input.

Hi Max,

As Bruce suggested, you can simply create the event instance and call
"Raise" method to raise it. Also, it support creating custom event, here
are some articles describing this:

#How To: Use Health Monitoring in ASP.NET 2.0
http://msdn2.microsoft.com/en-us/lib...ht000011_step1

#Raising Custom ASP.NET Health Monitoring Events Example
http://msdn2.microsoft.com/en-us/library/ms227545.aspx

Sincerely,

Steven Cheng

Microsoft MSDN Online Support Lead
This posting is provided "AS IS" with no warranties, and confers no rights.


--------------------
>Date: Wed, 24 Oct 2007 13:04:07 -0700
From: bruce barker <no****@nospam.com>
MIME-Version: 1.0
Subject: Re: How to raise a WebBaseErrorEvent or WebManagementEvent

(new WebRequestEvent("my message",
null,
WebEventCodes.WebExtendedbase +1)).Raise();

-- bruce (sqlworkcom)

Max2006 wrote:
>Hi,

We are using ASP.NET 2.0 health and monitoring provider.
I know that the platform raises events automatically.

I just wanted to know how can we raise them in C# code? I am trying to
raise
>WebBaseErrorEvent or WebManagementEvent.

Thank you,
Max

Oct 25 '07 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: James Stroud | last post by:
Hello All, Is this a bug? Why is this tuple getting unpacked by raise? Am I missing some subtle logic? Why does print not work the same way as raise? Both are statements. Why does raise need to...
2
by: Bogdan Zamfir | last post by:
Hi, I have a problem with err.raise I write a class module, and I want to use this mechanism to indicate errors when user set wrong values to properties But it seems the error is never raised...
1
by: Dan Cimpoiesu | last post by:
I have a remoting object, derived from MarshalByRefComponent, that I instantiate on the client side, with Activator.GetObject. Can I receive events fired on the server, on the client? How?
2
by: Andrew | last post by:
Hi, friends, I need to raise certain events in my VC# windows control library. Any reference paper or sample source code for help? Thanks a lot...
4
by: Frank | last post by:
Hi, what should I use to raise an error: RAISE or THROW And I am asking this with regard to the future VB.NET developments. Is Raise the old way and Throw the new? Throw does not have parms to...
7
by: Steven W. Orr | last post by:
In my class I have class Error(Exception): """Base class for exceptions in this module.""" pass class TransitionError(Error): """Raised when an operation attempts a state transition that's...
5
by: Mike | last post by:
Hi group; Let say I have an object called Account, that raises an event called AccountLow with its owns EventArgs, and when this event gets raised, I will like to raise another custom...
9
by: ssecorp | last post by:
Is this correct use of exceptions? to raise an indexerror and add my own string insetad of just letting it raise a IndexError by itself and "blaming" it on list.pop? class Stack(object): def...
14
by: Rafe | last post by:
Hi, I've encountered a problem which is making debugging less obvious than it should be. The @property decorator doesn't always raise exceptions. It seems like it is bound to the class but...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.