For i = 1 To 9
If Request.Form("step" & i) <> strStep(i) Then
alertstep(i) = True
End If
For i = 1 To 9
If alertstep(i) Then
response.write "Step " & i & " has been updated, you now need to ...."
End If
MS Access and all other databases that I know store dates as datetimes. Even when you enter only a date, it will return this date as a datetime, where the timepart is 00:00:00
The function datevalue returns only the datepart of a string that represents a date(time) but also of a real datetime...
You should use the randomize statement with no arguments, to inialize the random-number generator with a seed based on the system timer, before calling Rnd.
Randomize
For i = 1 To 9
number(i) = Rnd(46) + 1
Next
Oh, I'm sorry, it says only type mismatch...
However, I think this is still the problem, I've never had a type mismtach error or something by executing the .EOF function!
You're all foccusing at the wrong line! The error message is quit clear what is wrong:
'Data type mistmatch in citeria expression'
The error occurs in the line:
rs.Open SQLQuery, MyConn
So the code stops there, the rest of the code will not be executed. You have to look in the WHERE clause...
It's not your connection:
strSQL = "SELECT Staff.StaffID, Staff.Lname, Staff.Fname, Staff.Address FROM Staff WHERE Staff.StaffID = " & forms![Setup]![Combo5]
The discussion whether you should store the default MSSQL 2005 Express Membership database in the App_Data folder or somewhere else is not really an answer to the question. The question was 'if all the data should be tranfered to this database or not?'
The answer is NO, you can also build your...
Why not use DateSerial and Format?
_Year = Year(date())
_Month = Month(date())
For i = 0 to 17
strMonth = Format(DateSerial(_Year, (_Month + i), 1), "mmm yyyy")
Next
databasepath = "c:\test.mdb"
sSQL = "SELECT ID, name FROM test"
Set conn = Server.CreateObject("ADODB.Connection")
conn.Open "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & databasepath
Set rsTest = Server.CreateObject("ADODB.Recordset")
With rsTest
'to use adLockReadOnly and...
If the date type of tempTable.date is text this is the result I would expect. Every date, except for jan 1th in years before 2007 are smaller then '01/01/2007'. If you would stick to date type text then you should store the dates in yyyy/mm/dd format, the better option is change the date type to...
It's no problem to use a database in another folder, but make sure that it cannot be downloaded by an http request (in the past you would put the database in a folder outside the wwwroot).
In ASP.NET, files the App_Data folder (within the wwwroot) cannot be downloaded by an http request either
I don't think this is the right forum for your question, but never mind.
The reason that you can't read the selected value for search1 is because all values are "".
<option value="">
should be something like
<option value="<%=recordSet("ID")%>">
where ID is the ID field of your table.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.