JS onclick to show data of the selected row in a new browser window.

Hi I have a datatable populated from ListDataModel there is a commandButton at the end of each row, how can I get the selected row in javascript using onclick.

Basically when a user clicks on the button I want to open a new browser window and show the values of the selected row. Can someone please tell me how can i achieve this.

Thanks

[356 byte] By [whitesox12a] at [2007-11-27 11:43:46]
# 1

Use the binding attribute of the dataTable to get the UIData instance and use UIData.getRowData(). Google for details if you need them.

RaymondDeCampoa at 2007-7-29 17:51:51 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 2

Thanks but how do I show this data in new browser window i.e. something like window.open('#{backingBean.selectedrow}')

Want to open a new window like a dialog box and show the data on top of the current window.

Thanks

whitesox12a at 2007-7-29 17:51:51 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 3

Use the target attribute of the form component or any number of javascript techniques. Search the forum, this has been asked many times.

RaymondDeCampoa at 2007-7-29 17:51:51 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...