473,486 Members | 1,733 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

How to pass args for events

Hi

Please let me know how to do the following

here, i have property and event in a class, now i want to fire the
event from the property when i get value, how to pass args for the
below event

would you FILL UP THE (?) MARK .

Property required() As Boolean
Get
Return m_required
End Get
Set(ByVal Value As Boolean)
m_required = Value
If Value = True Then
EVENTVALIDATING( ? , ? )
End If
End Set
End Property

Private Sub eventvalidating(ByVal sender As Object, ByVal e As
System.ComponentModel.CancelEventArgs) Handles MyBase.Validating
If Me.Text = "" Then
e.Cancel = True
showerr("Only Alphabets")
Me.Focus()
End If
End Sub

Thanks

Apr 27 '07 #1
1 1398
On Apr 27, 7:40 am, spaulsa...@yahoo.co.in wrote:
Hi

Please let me know how to do the following

here, i have property and event in a class, now i want to fire the
event from the property when i get value, how to pass args for the
below event

would you FILL UP THE (?) MARK .

Property required() As Boolean
Get
Return m_required
End Get
Set(ByVal Value As Boolean)
m_required = Value
If Value = True Then
EVENTVALIDATING( ? , ? )
End If
End Set
End Property

Private Sub eventvalidating(ByVal sender As Object, ByVal e As
System.ComponentModel.CancelEventArgs) Handles MyBase.Validating
If Me.Text = "" Then
e.Cancel = True
showerr("Only Alphabets")
Me.Focus()
End If
End Sub

Thanks
Since you're talking about calling the base object's Validating event,
you could do what the base object does and just call it's OnValidating
method:

MyBase.OnValidating(New
System.ComponentModel.CancelEventArgs())

Thanks,

Seth Rowe

Apr 27 '07 #2

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

Similar topics

6
6617
by: Harri Pesonen | last post by:
How do I pass the calling C++ class reference (or anything) to a callback? My code is: static PyObject* emb_Set(PyObject *self, PyObject *args) { char *key, *value; if(!PyArg_ParseTuple(args,...
0
2424
by: Matt | last post by:
My problem is to allow ASP to interact with JSP, and I pass JavaScript object in my approach, but I wonder if it will work in network, not just in local machine. For testing purposes, the...
12
38452
by: Huskier | last post by:
Hi all: I want to pass a class-member function to pthread_create, and my code is in the following, but I don't know how to pass myobj.thread_function to pthread_create function. #include...
4
21330
by: Ron | last post by:
Hello, how do you pass args to a console app? class TestApp { static void Main(string args) { // // TODO: Add code to start application here
1
2183
by: Sivaraman.S | last post by:
Hi, Can i pass integer array to methodInfo.Invoke(obj,args()). I am able to pass only string array to this function. This is the code i have written. Dim myType As Type = objClass.GetType()...
4
9375
by: tony.ha | last post by:
Hello, I have open a Python program in the IDLE, but when I select the "run module" under "run" menu, it does not allow me to pass an argument to my Python program! How do you pass an argument...
1
9432
by: skillzero | last post by:
Is there a portable way to pass a va_list as a parameter to another function taking a variable argument list? I have a function that takes a printf-like format string and I'd like to use...
24
55011
by: =?Utf-8?B?U3dhcHB5?= | last post by:
Can anyone suggest me to pass more parameters other than two parameter for events like the following? Event: Onbutton_click(object sender, EventArgs e)" Event handler: button.Click += new...
3
2380
by: swetha123 | last post by:
hello, I don't know how to use cookies please help me in this I am using the dream weaver cs4 I designed the navigation bar to my page using dream weaver cs4 navigation bar contains...
0
7094
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
7173
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
6839
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
5427
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,...
1
4863
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...
0
4559
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3066
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
3070
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
259
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

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.