And one more thing you people are missing double quote and + sign to write inside alert
string username=(gridview.row[0].Cells[0].Text).tostring();
string s=username+"Record Updated successfully";
ScriptManager.RegisterStartupScript(this, this.GetType(), "RunCode", "javascript:alert('"+s+"');", true);