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

label web control click event

is there any way that i can create a click event for a label that is
part of the web control library....i want to use a label in a user
control, and when the user clicks one the user control i wanna change
the color of the label to red for example....i tried importing
system.web.ui.webcontrol.label but there is no click event for the
label, so is there a way i can create it

thanks
sam

--
Sent via .NET Newsgroups
http://www.dotnetnewsgroups.com
Dec 14 '05 #1
2 1784
derive from the existing labelcontrol to create your control and implement a
ipostback handler and expose a event on label click

lable is span in html so just check outwith the span clientside event to
which you want to map the postback

"semesm22" wrote:
is there any way that i can create a click event for a label that is
part of the web control library....i want to use a label in a user
control, and when the user clicks one the user control i wanna change
the color of the label to red for example....i tried importing
system.web.ui.webcontrol.label but there is no click event for the
label, so is there a way i can create it

thanks
sam

--
Sent via .NET Newsgroups
http://www.dotnetnewsgroups.com

Dec 14 '05 #2
derive from the existing labelcontrol to create your control and
implement a
ipostback handler and expose a event on label click
the problem is that i am creating the label inside a user control,
therefor the click event needs to be coded in the user control, cause
the form will only see a user control, and not a label...that correct,
right?

thanks
sam

--
Sent via .NET Newsgroups
http://www.dotnetnewsgroups.com
Dec 14 '05 #3

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

Similar topics

5
by: Sambo | last post by:
I have two forms, frmMain and frmSettings. I have a label in frmMain that i would like to change from frmSettings. So when the user clicks the command button in frmSettings then a value from a...
1
by: Henke | last post by:
Hello, I have one ImageButton controls which I initialize in Page_Load and declare on class level. ImageButton save = new ImageButton(); save.ImageUrl = "save.gif" save.Click += new...
31
by: jcrouse | last post by:
Is there a quick and easy way to change the color of a label controls border from the default black to white? Thank you, John
6
by: jcrouse | last post by:
I am rotating some text is some label controls. In the one place I use it it works fine. In the other place I use it I can't figure out the syntax. I don't really understand the event. Where it...
3
by: Neil Wallace | last post by:
Hi, This is an odd one. I've been struggling to get "double click" to work well for my controls. The same event handler works perfectly for buttons, but not for labels. Can anyone tell me...
3
by: Mike | last post by:
Need some help with passing a label to a subroutine. I have a form with lots of checkboxes. When the form loads i have a procedure that runs to lookup values and check the appropriate boxes. If the...
12
by: vbnewbie | last post by:
I am having problems accessing properties of dynamically generated objects in VB2005. Can someone please help? In a nutshell: My app creates an equal number of checkboxes and labels that share the...
3
by: sheenaa | last post by:
Hello friends, I m using ASP.NET with C# 2005 and SQL SERVER 2005 for the ASP.Net Website. I m using sqldatasource to connect and retrieve the data from database and then it displays the data...
18
by: navyjax2 | last post by:
What if your event handler has to be nonstatic?
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
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
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,...

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.