1

グリッドの [Viewdtails] ボタンをクリックすると、そのすぐ下にある [例外の詳細] グリッドが表示されるデータ グリッド ビューがあります。それは問題なく動作しますが、ユーザーが表示できるように履歴グリッドを作成する 2 番目のクエリがありますが、これをコメント解除して実行すると、「メソッドまたは操作が実装されていません」というエラーが表示されます。そして、私の最初のクエリは結果をまったく返しません。これを書き直して、両方のクエリを実行し、両方のグリッドに入力するにはどうすればよいですか?

   Protected Sub CountAlerts_RowCommand(ByVal sender As Object, ByVal e As System.Web.UI.WebControls.GridViewCommandEventArgs) Handles CountAlerts.RowCommand
    If (e.CommandName = "Viewdtails") Then
        Dim index As Integer = Convert.ToInt32(e.CommandArgument)

        Dim abc, Unit, Cell, DTTM, prod, Query As String
        'Dim qry2 As String
        Dim DS As DataSet
        'Dim DS2 As DataSet

        abc = CountAlerts.DataKeys(index).Values("ABC")
        Cell = CountAlerts.DataKeys(index).Values("Cell")
        Unit = CountAlerts.DataKeys(index).Values("Unit")
        DTTM = CountAlerts.DataKeys(index).Values("CycTimeDate")
        prod = CountAlerts.DataKeys(index).Values("ProductDesc")

        For Each irow As GridViewRow In CountAlerts.Rows
            If irow.Attributes("class") = "highlight" Then
                irow.Attributes.Remove("class")
            End If
        Next

        CountAlerts.Rows(index).Attributes("class") = "highlight"
        Query = "EXEC [Audits].[dbo].[DetailsCombined] '" & abc & "', '" & Cell & "', '" & Unit & "', '" & DTTM & "', '" & User.Viewing & "' "
        DS = SelectQuery(Query)
        ExceptionDetails.DataSource = DS
        ExceptionDetails.DataBind()

        'qry2 = "EXEC [Audits].[dbo].[TrackerCombined] '" & abc & "', '" & Cell & "', '" & Unit & "', '" & StartDate.Text & "', '" & EndDate.Text & "', '" & User.Viewing & "' "
        'DS2 = SelectQuery(qry2)
        'ExceptionHist.DataSource = DS2
        'ExceptionHist.DataBind()

    End If
End Sub
4

0 に答える 0