473,322 Members | 1,405 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,322 software developers and data experts.

how to declare custom event in interface

hey all,
i have a working example of a simple event delegation:

http://pastebin.com/m104a6c1f

can someone please show me how to define my custom event in an interface?

thanks,
rodchar
Jul 30 '08 #1
2 3054
On Jul 30, 11:20*am, rodchar <rodc...@discussions.microsoft.com>
wrote:
hey all,
i have a working example of a simple event delegation:

http://pastebin.com/m104a6c1f

can someone please show me how to define my custom event in an interface?

thanks,
rodchar
public interface ISystemEditorView {

event EventHandler<InitializeEventArgsInitialize;

event EventHandler<InitializeDataEventArgsInitializeData ;
}
Jul 30 '08 #2
On Jul 30, 11:20*am, rodchar <rodc...@discussions.microsoft.com>
wrote:
hey all,
i have a working example of a simple event delegation:

http://pastebin.com/m104a6c1f

can someone please show me how to define my custom event in an interface?

thanks,
rodchar
of course, you have to define your classes deriving from EventArgs:

public class InitializeEventArgs: EventArgs {

private Form form;

public Form Form {
get { return form; }
set { form = value; }
}

}
Jul 30 '08 #3

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

Similar topics

7
by: Luc Tremblay | last post by:
Given the typical following code: void Listener::HandleEvent(const Event& event) { // handling code } In a "clean" fashion, how is it possible to add custom data (to be subsequently...
2
by: Derrick | last post by:
How does one declare an event within an interface, so that every class which implements that interface must implement that event? I think I just need to specifiy the actual event as I would a...
2
by: Juan Romero | last post by:
Hey guys, I am working on a web custom control that basically draws a table (ASP Table) with a few child controls in the cells. I have a command button inside one of these cells. The problem I...
21
by: One Handed Man \( OHM - Terry Burns \) | last post by:
When using a custom control. In order to check and see if values have changed one has to implement the IPostBackDataCollection interface. The values returned for the control seem to be simply a...
10
by: Rigs | last post by:
Hi, I have a textbox with a Custom Validator that utilizes the OnServerValidate method for that textbox. This works fine, however the method only executes when data exists in that textbox after...
1
by: Pavan | last post by:
Hi All, I have created a custom DataList web custom control, which populates data from a dataset. This dataset is available at runtime and exposed as property by my custom control. During...
1
by: Gene | last post by:
I would like to know if the following is even possible with the visual studio.net Setup and Deployment project. 1. During the deployment after creation of application directory the setup needs...
0
by: Reshma Prabhu | last post by:
Hi, I have created a custom control derived from CompositeControl class. It implements the IPostBackEventHandler interface. It consists of multiple child controls which are hyperlinks which post...
1
by: RSH | last post by:
I am testing a few concepts in preparation of a project. One of the concepts revolves around a custom dropdownlist class. Basically I am overriding the RenderContents and writing a custom value...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 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 former...

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.