Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
1365
Enters in rowtemplate
posted

Dear Infragistics,

We have a hierarchical datagrid with a rowtemplate. In that rowtemplate we have an image which needs to call a javascript on click. It passes along as a variable a piece of XML. This works fine.

Looks like this: .RowTemplate("<td> {{if (${HasTemplate} =='true')}} <input type=\"image\" src=\"" + @Url.Content("~/Resources/MagnifyingGlass.png") + "\" align=\"left\" title=\"Details bekijken\" alt=\"Details bekijken\" onclick=\"popUpTemplate('${Template}');\"/> {{/if}} </td>")

Except when the content (see: ${Template}) contains enters (\r\n), then it seems the onclick is never set. I say never set, because I've put a breakpoint at the 1st line in the javascript popUpTemplate and it's never hits that breakpoint (debugged in Firebug).

Ofcourse the easy way out is to do something clever with the /r/n's, but I thought perhaps you've encountered this behaviour before and know how to properly tackle it.

Thank you very much in advance for replying.

Parents Reply Children
No Data