ボタンクリックでresponse.redirectを使用して、新しいタブまたは新しいページを開きたいとします。私はいくつかの値を渡すためにクエリ文字列を使用しています。新しいタブでページを開く方法。レスポンスを使用して新しいタブでページを開く方法。 asp.netでリダイレクト
protected void btnSave_Click(object sender, EventArgs e)
{
...//some code to insert records
Response.Redirect("NewQuote.aspx?val=" + this.txtQuotationNo.Text);//displaying gridview in other page to print what needed
}
このコードは動作していますが、同じページで開きます。私は新しいタブで開く必要があります –
LinkButtonsとtarget = "_ blank"を見てください – mybirthname
これを試してください:http://stackoverflow.com/questions/16896284/opening-a-url-in-a-new-tab – SenthilPrabhu