I have a radgrid with a GridImageColumn. I display a thumbnail image in the image column form a data base. I have set the Grid's onrowdblclick to instantiate some java to popup a radwindow with a larger version of the image.
Everything works great... EXCEPT, if the user double clicks the actual thumbnail image. Nothing happens. Is there a way to either make the GridImageColumn or the thumbnail image also call the java script like the onrowdblclick event?
Everything works great... EXCEPT, if the user double clicks the actual thumbnail image. Nothing happens. Is there a way to either make the GridImageColumn or the thumbnail image also call the java script like the onrowdblclick event?
<script type="text/javascript"> |
function RowClick(sender, eventArgs) { |
var MasterTableView = eventArgs.get_tableView(); |
var cell = MasterTableView.getCellByColumnUniqueName(MasterTableView.get_dataItems()[eventArgs.get_itemIndexHierarchical()], "IDImages"); |
var oWnd = radopen("../../imagemanager/imagedisplay.aspx?IDImages=" + cell.innerHTML); |
} |
</script> |
<telerik:RadGrid ID="rg_VehicleImages" runat="server" |
AllowAutomaticDeletes="True" AutoGenerateDeleteColumn="True" CssClass="radgrid" |
DataSourceID="sds_ImagesVehicle" GridLines="None" Width="220px"> |
<mastertableview autogeneratecolumns="False" datakeynames="IDImages" |
datasourceid="sds_ImagesVehicle"> |
<rowindicatorcolumn> |
<HeaderStyle Width="20px" /> |
</rowindicatorcolumn> |
<expandcollapsecolumn> |
<HeaderStyle Width="20px" /> |
</expandcollapsecolumn> |
<Columns> |
<telerik:GridBoundColumn DataField="IDimages" DefaultInsertValue="" |
HeaderText="" ItemStyle-ForeColor="White" ItemStyle-Width="2px" |
SortExpression="True"> |
<HeaderStyle Width="2px" /> |
</telerik:GridBoundColumn> |
<telerik:GridImageColumn AlternateText="Thumbnail" |
DataImageUrlFields="FilePath, ThumbnailName" DataImageUrlFormatString="{0}/{1}" |
DataType="System.String" FooterText="ImageColumn footer" HeaderText="" |
ImageAlign="Middle"> |
<HeaderStyle Width="75px" /> |
</telerik:GridImageColumn> |
<telerik:GridBoundColumn DataField="ThumbnailName" DefaultInsertValue="" |
HeaderText="ThumbnailName" SortExpression="ThumbnailName" |
UniqueName="ThumbnailName" Visible="False"> |
</telerik:GridBoundColumn> |
</Columns> |
</mastertableview> |
<clientsettings> |
<clientevents onrowdblclick="RowClick"/> |
</clientsettings> |
</telerik:RadGrid> |