asp.net - get data from database in aspx -
I am using VS 2010 to develop a site that receives some data from the database.
But I just keep going to this error.
'No value has been given for one or more essential standards.'
This is my code
public function getSessionDetails (by as Wall Room ID string) ArrayList Dim sql As String sql = "SELECT * Table1 WHERE RoomId =?" The dbComm dim new OleDbCommand (SQL, dbConn) 'dbComm.Connection.Open () dbComm.CommandText = SQL dbComm.Parameters.Add ( "RoomId", System.Data.OleDb.OleDbType.BSTR) .Value = roomId dbConn.Open as () 'DbComm.ExecuteNonQuery () dim dbRead as OleDbDataReader = dbComm.ExecuteReader ()' System.Data.CommandBehavior.CloseConnection) try new ArrayList as dim arr dbRead.Read () arr.Add (new session Description (dbRead.GetValue (2) .ToString, dbRead.GetValue (3) .ToString, dbRead.GetValue (4) .ToString, dbRead.GetValue (6) .ToString, _ dbRead.GetValue (5) .ToString, dbRead .GetValue (7) .ToString, dbRead.GetValue (8) .ToString) Try to try endeavor while trying to end the arrival as the pre-exception For the basis of the date and the date of the bubble I use it as an integer to arr = 1. - 1 dim sesTop SessionDetails = Arrivals (i) Dim as sesBot as the session description = arr (i - 1) ) Details as a slow sesTmp session if sesBot.sessionDate & lt; ; - Arrival (i 1) = sesTmp i = 0 elseif sesBot.sessionDate = sesTop.sessionDate and sesBot.StartTime & lt - sesTop.sessionDate then they sesTmp = arr (i) Arrival (i) = arrival (1 i) Swap SesTop.StartTime then swap them sesTmp = arr (i) arr (i) = arr (i - 1) arr (i - 1) = sesTmp i = 0 expires if the next catch is finished as expiry 'Dim se as 'Session date' and 'lt; s' in every 'ar'
Thanks for any help
>
Change these two lines
gross = "SELECT * fROM Tablel WHERE RoomId = @rumid" Dbkm Kparamitrskaed ( "@ Rumid" Sistmkdetakoledbkoledbteepekbstr) Kvalu = Rumid
Comments
Post a Comment