Click here to Skip to main content
15,902,198 members

Comments by Member 9989624 (Top 34 by date)

Member 9989624 28-Jul-13 3:11am View    
its very simple query. I got it sorted.
Member 9989624 13-Jun-13 0:55am View    
In Sql i get the correct value.
Member 9989624 13-Jun-13 0:27am View    
I use the below code, this says error Index was outside the bounds of the array.. Please help

Dim connString As String = "Provider=SQLOLEDB.1;Password=$impadmins123;Persist Security Info=True;User ID=simp;Initial Catalog=Employee Information;Data Source=SRAVI6"
Dim conn As New OleDb.OleDbConnection(connString)
Dim sql As String = "SELECT count(EmployeeName) FROM AgentShiftRoster1 where Group1 ='" & Trim(ComboBox1.Text) & "'"
Dim cmd As New OleDb.OleDbCommand(sql, conn)
conn.Open()
Dim reader As OleDb.OleDbDataReader = cmd.ExecuteReader()
While reader.Read()
If reader(7) = Date.Today Then
TextBox1.Text = reader(2).ToString()
End If
End While
reader.Close()
conn.Close()
Member 9989624 8-Jun-13 1:06am View    
awarding points for wrong answer is not a good thing.
Member 9989624 8-Jun-13 1:05am View    
this isn't a bad design.