private void updateQuery() { string strSQL = @" UPDATE KPI_LOW SET QRY_DATA = @I_QRY_DATA, QRY_MS = @I_QRY_MS, QRY_TS = @I_QRY_TS WHERE KPI_REF_ID = @I_KPI_REF_ID "; IDbDataParameter[] arrOpm = DbAgentBase.CreateDataParameters(4); arrOpm[0] = DbAgentBase.CreateDataParameter("@I_QRY_DATA", SqlDbType.VarChar, 1000); arrOpm[0].Value = txtQRY_DATA.Text; arrOpm[1] = DbAgentBase.CreateDataParameter("@I_QRY_MS", SqlDbType.VarChar, 1000); arrOpm[1].Value = txtQRY_MS.Text; arrOpm[2] = DbAgentBase.CreateDataParameter("@I_QRY_TS", SqlDbType.VarChar, 1000); arrOpm[2].Value = txtQRY_TS.Text; arrOpm[3] = DbAgentBase.CreateDataParameter("@I_KPI_REF_ID", SqlDbType.Int, 8); arrOpm[3].Value = int.Parse(hdnKpiRefID.Value.ToString()); int intRtn = DbAgentHelper.CreateDbAgent().ExecuteNonQuery(strSQL, arrOpm, CommandType.Text); }