Author |
Topic |
|
StephenD
Senior Member
Australia
1044 Posts |
Posted - 04 May 2005 : 08:59:20
|
Calendar Mod non-recurring, 3.4.05, MSSQL I get an error when viewing cal.asp in Weekly View and only when logged in as an Administrator.
Error is: Microsoft VBScript runtime error '800a01a8'
Object required
/cal.asp, line 366 = (if not rs.EOF then)
The code relates to the subweeklyview.
This is the same error as discussed in this old post but no fix was offered: http://forum.snitz.com/forum/topic.asp?ARCHIVE=true&TOPIC_ID=45695
Anyone got any ideas on the error. |
|
Shaggy
Support Moderator
Ireland
6780 Posts |
Posted - 04 May 2005 : 09:02:57
|
That error means that there is no rs object available for your code to use. Check that the recordset is actually open and that its name is rs.
|
Search is your friend “I was having a mildly paranoid day, mostly due to the fact that the mad priest lady from over the river had taken to nailing weasels to my front door again.” |
|
|
StephenD
Senior Member
Australia
1044 Posts |
Posted - 04 May 2005 : 20:13:34
|
OK, the error does not occur when you are logged in as a normal user. The Weekly View works fine. Log in as an Admin and the weekly view fails. The other views work ok. Changing who is allowed to add an event makes no difference either. |
|
|
Shaggy
Support Moderator
Ireland
6780 Posts |
Posted - 05 May 2005 : 04:51:00
|
Can you post a link to a *.txt copy of your cal.asp file?
|
Search is your friend “I was having a mildly paranoid day, mostly due to the fact that the mad priest lady from over the river had taken to nailing weasels to my front door again.” |
|
|
StephenD
Senior Member
Australia
1044 Posts |
Posted - 05 May 2005 : 05:01:50
|
Sure, cal.txt |
|
|
Shaggy
Support Moderator
Ireland
6780 Posts |
Posted - 05 May 2005 : 05:31:34
|
Ooo, 'eck; that's a whole mess of code! Can't see anything immediately that would cause the problem - gimme another hour or 2 to wake up properly and I'll have another look at it. One thing you could try is adding a counter* to see if it's crapping out on the first record or if there's something going skewways within the loops itself.
*Immediately before the do loop starts create a new variable and give it a value of 0, immediately after starting the do loop do a response.write on that vriable and just before closing the loop increment the variable by one.
|
Search is your friend “I was having a mildly paranoid day, mostly due to the fact that the mad priest lady from over the river had taken to nailing weasels to my front door again.” |
|
|
StephenD
Senior Member
Australia
1044 Posts |
Posted - 09 May 2005 : 01:47:27
|
Fixed, needed a Dim RS on Line 353:"AND C.CAT_ID = T.CAT_ID " & _
"ORDER BY T.T_EVENT_DATE Asc"
Dim rs
set rs = Server.CreateObject("ADODB.Recordset")
rs.Open StrSql, My_conn
|
|
|
Shaggy
Support Moderator
Ireland
6780 Posts |
Posted - 09 May 2005 : 07:55:51
|
Phew! Don't feel quite so stupid now; was looking at this a couple of times over the weekend, wondering where the bleedin' error was - would never have thought of dimensioning the rs object as I rarely use "option explicit".
|
Search is your friend “I was having a mildly paranoid day, mostly due to the fact that the mad priest lady from over the river had taken to nailing weasels to my front door again.” |
|
|
|
Topic |
|