Add OnItemCommand="grdAppCond_ItemCommand" to Grid Tag on your aspx page. The following method will be invoked. Check that e.CommandName is equal to the text of cell of your grid.
protected void grdAppCond_ItemCommand(object source, GridCommandEventArgs e)
{
if (e.CommandName == "Open Window")
{
this.OpenWindow();
}
}
Add the following method to your .cs file. This method will call the javascript funtion openPopup.
private void OpenWindow()
{
string script = "<script language='javascript' type='text/javascript'>openPopup()</script>";
ClientScript.RegisterStartupScript(this.GetType(), "openPopup", script);
}
Now in your aspx page add the following code (batter on end).
<script type="text/javascript">
function openPopup() {
var id = '<%= id%>';
var url = quot;WindowPath.aspx?ID=quot; + id;
window.open(url, "window1", "scrollbars=1, width=950px, height=560px, resizable=0");
}
</script>
Now you can get the id on your target page using Query String