我正在研究Asp.net,C#應用程序。 我想點擊「更新」LinkButton後刷新網頁;在網格視圖中。我已經嘗試了下面的代碼;但它只刷新頁面而不在Grid視圖中保存更新的數據。如何在網格視圖中單擊「更新」後刷新網頁
protected void LinkButton1_Click1(object sender, EventArgs e)
{
Response.Redirect(Request.RawUrl.ToString());
}
數據源SqlDataSourcePlan
SELECT [PlanID], [Deposit], [DepositReturn], [Discount] FROM [PaymentPlan] WHERE ([Ref] = @Ref)
UPDATE [PaymentPlan] SET [Deposit] = @Deposit, [DepositReturn] = @DepositReturn, [Discount] = @Discount WHERE [PlanID] = @original_PlanID
如何試圖調試代碼以找出在PageLoad方法中加載頁面中的信息?什麼是你的GridView的數據源? –