473,396 Members | 1,895 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.

Making a TableCell Appear Clickable

I have navigation that is made out of a table. I did this so that I could
dynamically create my "buttons" (the cells formatted using CSS) and avoid
creating a new graphic every time I changed the text of a button. However,
because TableCells are not clickable, this only allows the user to click on
the text used in the button. Because all my buttons are the same size, I was
wondering if there was a way to detect when and where (get the X & Y
coordinates) the user clicked and possibly use those to give the same
effect. Because the table containing the "buttons" will be in a User
Control, I do not have to worry about placement or the user's screen size.
But I am unsure if there is a way to get these coordinates from a click
event when the table does not have a click event? Any ideas? Thanks.
--
Nathan Sokalski
nj********@hotmail.com
http://www.nathansokalski.com/
Nov 19 '05 #1
1 2547
Nathan,

TableCell is as clickable as any other html control. Just add "onclick"
attribute and provide a javascript handler for client-side onclick event.
You don't even need to pace any buttons inside the cells.

Eliyahu

"Nathan Sokalski" <nj********@hotmail.com> wrote in message
news:uF**************@TK2MSFTNGP09.phx.gbl...
I have navigation that is made out of a table. I did this so that I could
dynamically create my "buttons" (the cells formatted using CSS) and avoid
creating a new graphic every time I changed the text of a button. However,
because TableCells are not clickable, this only allows the user to click on the text used in the button. Because all my buttons are the same size, I was wondering if there was a way to detect when and where (get the X & Y
coordinates) the user clicked and possibly use those to give the same
effect. Because the table containing the "buttons" will be in a User
Control, I do not have to worry about placement or the user's screen size.
But I am unsure if there is a way to get these coordinates from a click
event when the table does not have a click event? Any ideas? Thanks.
--
Nathan Sokalski
nj********@hotmail.com
http://www.nathansokalski.com/

Nov 19 '05 #2

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

Similar topics

14
by: Jeff Gillingham | last post by:
I'm using a stylesheet to place a small 'background image' in the upper left corner of several pages. Is there a simple way of making that image a clickable link? Thanks.
2
by: George Durzi | last post by:
Consider this pseudo HTML from a web form <asp:Table> <asp:TableRow> <asp:TableCell> <asp:Table> <asp:TableRow> <asp:TableCell></asp:TableCell> <asp:TableCell></asp:TableCell>...
6
by: hb | last post by:
Hi, I have a page bill.aspx and its code-behind bill.aspx.cs. On bill.aspx I have: === Select a month: <asp:dropdownlist runat="server" id="lstDate" autopostback="True" /> <br> <asp:table...
0
by: Diane Yocom | last post by:
I'm very new to ASP.Net and probably jumped in a little over my head, but... I'm trying to create a user control that will control navigation through my site. It's sortof like Amazon.com, where...
2
by: Michael | last post by:
Need some help trying to read values from web controls - specifically *finding* the controls (like a drop down list) - that are added dynamically added within an asp:panel control. The page...
0
by: Slim | last post by:
I have page that takes some counties from a database and builds a table adding a cell with a button to each row. I have attached a event to each button when clicked it builds a second table that...
3
by: crazychrisy54 | last post by:
Hi there I just wondered if there is any way using GD to insert a clickable button or some clickable text into a image? It is possible to create images for buttons but what if you want a...
3
by: zb42 | last post by:
I have a _mc that I've added to the stage. On it's layers first frame I have this code that spins the _mc around and has some great effects: import fl.transitions.*; import...
2
by: AAaron123 | last post by:
I have a tablecell containing two radio buttons. I have two htm files. If one button is checked I'd like one of the file's contents to show. If the other button is checked I like the other file's...
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:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
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...
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...

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.