09-08-22, 02:03 PM
كود :
Dim CodeOrderType As String = Me.TextBox1.Text
Dim Sql As String = "SELECT IIF(SUM(Order_Total) Is Null,0,SUM(Order_Total)) As SumOrders From Table Where Order_Type = '" & CodeOrderType & "'"
Dim Cmd As SqlCommand = New SqlCommand(Sql, Conne)
Dim DA As SqlDataAdapter = New SqlDataAdapter(Cmd)
Dim DT As DataTable = New DataTable
DA.Fill(DT)
Me.TextBox2.Text = DT.Rows(0)(0).ToStringقناتنا على اليوتوب
