aspose file tools*
The moose likes HTML, CSS and JavaScript and the fly likes Finding Table Cell co-ordination Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of The Java EE 7 Tutorial Volume 1 or Volume 2 this week in the Java EE forum
or jQuery UI in Action in the JavaScript forum!
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "Finding Table Cell co-ordination" Watch "Finding Table Cell co-ordination" New topic
Author

Finding Table Cell co-ordination

Tokai Moshai
Greenhorn

Joined: May 24, 2006
Posts: 16
Say I have a table with 3 rows and 3 columns (to keep it simple, in real case it is going to be dynamic). Each of the cell has a hyperlink that calls a function. What need to know is, is there any way to know which cell was clicked using some javascript function?

If I'm not clear,

say I have

<td><a href="javascript:myFunc()"</a></td>

what I need is something like
<td><a href="javascript:myFunc(TableXcoord,TableYcoord)"</a></td>

I'm not able to put those TableXcoord, TableYcoord values when creating the table. so, is there anything like rows[mouse_click].cells[mouse_click]?

Or is there any other way I can solve this problem? I'm not able to put the row values the table that is being created by a class that creates all the cells of the column at the same time. I can put the column values.

Please let me know if I'm still not clear.
Tokai Moshai
Greenhorn

Joined: May 24, 2006
Posts: 16
I found it:

use OnClick with window.event.srcElement.recordNumber
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Finding Table Cell co-ordination