Hi,

I want to make a query with SUM function in SQL. Ill get a value not a table. So I dont want to use a datagridview for it. Is it possible to get this value?

I make the query with this code normally:
Code:
        Dim DS As New DataSet
        Dim OL As New SqlClient.SqlDataAdapter("", CN)


        DGW.DataSource = Nothing
        DS.Tables.Clear()
        DS.DataSetName = "NewDataSet"


        CN.Close()

        Connect(UserName, Password, DBPlace)
        OL.SelectCommand.CommandText = Command 'This String parameter is being taken in the sub

        DS.Tables.Add(Table) 'Table string parameter is being taken too
        OL.Fill(DS.Tables(Table))
        DS.DataSetName = CN.ConnectionString
        DGW.DataSource = DS.Tables(Table)

Thanks for any help...