Syntax for calling a javascript function

R

Renuka

I am getting an error in the Action line, where I am trying to send
the ID(retreived from the database) to a javascript function. Please
help me with the exact syntax as I am new to C#.

case "CR":
sSql = "SELECT DISTINCT "

//Error
+ "'Action' = '<center><a
href='+char(34)+'char(34)javascript:NewWindow('+cast(ChangeRequest.ChangeRequest_ID
as nvarchar))" '+CHAR(34)+)'>Open</a></center>',"//PSH sorting

+ "'Number' = ChangeRequest.ChangeRequest_ID,"+"'Title' =
ChangeRequest.Title,";
if(bAssignedTo)
{
sSql += "'Status' = CRAssignments.CRcStatus ";
}
else
{
sSql += "'Status' = ChangeRequest.Status ";
}
sSql += "FROM ChangeRequest LEFT JOIN CRAssignments on
ChangeRequest.ChangeRequest_ID=CRAssignments.CRnCR_ID ";

break;
 

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

No members online now.

Forum statistics

Threads
473,754
Messages
2,569,528
Members
45,000
Latest member
MurrayKeync

Latest Threads

Top