How to reteive values from the table and store them in a variable
Hi
i need to perform a calculation in my code and i need the values to be retrived from Table1, so far i took this approach:
[code]
Dim con AsNew SqlConnection(ConfigurationManager.ConnectionStrin gs("test").ConnectionString)
Dim cmdd AsNew SqlCommand("select NumberEmailSent from Users Where Name= @Name")
cmdd.Parameters.Add("@Name", Data.SqlDbType.NVarChar, 50).Value = Me.Label4.Text
cmdd.Connection = con
con.Open()
cmdd.ExecuteNonQuery()
con.Close()
???????????
[code/]
This code get ste value but i don know how to store it in a variable so i can perform the calculation.
the calculation gonna be (NumberEmailSend * Payrate1)
thanks
__________________
bx
|