try this :
you may use Template field of grid view .
<Columns>
<asp:TemplateField HeaderText="Path" Visible="false">
<ItemTemplate>
<asp:Label ID="Label1" runat="server" Text='<%#Eval("ID")%>' ></asp:Label>
</ItemTemplate>
</asp:TemplateField>
here ID is the Unique key for each data.
now,
use ROW data Command event of Grid.
protected void GridView1_RowCommand(object sender, GridViewCommandEventArgs e)
{
c.setcon();
if(e.CommandName.Equals("link"))
{
int index = System.Convert.ToInt32(e.CommandArgument);
Label l1 = (Label)GridView1.Rows[index].FindControl("Label1");
response.redirect("xyz.aspx?data_id='"+l1.toString()+"'");
}
}
this will help you...
if not , please post it what error come or your problem.
Mitesh