Visual Studio .Net webform designer question

G

Guest

Hi,

I have the following template column inside a datagrid:

<asp:TemplateColumn>
<ItemTemplate>
<a href="#" onclick="window.open('Respond.aspx?CaseNumber=<%#
Databinder.eval(container.dataitem, "CaseNumber") %>','newwin')">Respond</a>
</ItemTemplate>
</asp:TemplateColumn>

This is fine in VS.Net webform designer's HTML View. But when I try to
switch to Design mode I got the following error message:

Could not open in Design View. Quote values differently inside a '<%
...."value"... %>' block.

The template column actually works at run time, I can click on it and a new
window pops up.

Any Ideas?

TIA
 
K

Karl Seguin

This is an annoyance...try:

onclick='<%# "window.open('Respond.aspx?CaseNumber=" +
Databinder.eval(container.dataitem, "CaseNumber") + "','newwin')"%>'>

Karl
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,763
Messages
2,569,563
Members
45,039
Latest member
CasimiraVa

Latest Threads

Top