Author |
Topic |
GauravBhabu
Advanced Member
4288 Posts |
Posted - 11 August 2002 : 07:40:26
|
Add the event_repeat to the sql on Line 972 also. |
CSS and HTML4.01 Compilant Snitz Forum . ForumSquare . Rakesh Jain
It is difficult to IMPROVE on Perfection, There is no harm in Keep Trying.
Prayer Of Forgiveness "I forgive all living beings. May all living beings forgive me! I cherish the friendliness towards all and harbour enmity towards none." -- Aavashyaka Sutra(Translated) |
|
|
macho
Junior Member
Denmark
150 Posts |
Posted - 11 August 2002 : 08:01:16
|
quote: Originally posted by GauravBhabu
Add the event_repeat to the sql on Line 972 also.
Well, I did that but I still get the same error message when viewing events for a day:
ADODB.Fields error '800a0cc1' Unknown runtime error events_functions.asp, line 980
Also this looks a little strange to me (line 979 to 981):
Do While NOT Rs.EOF if EventRepeat(strtodate(Rs("START_DATE")), RS("EVENT_REPEAT"))then if (rs("PRIVATE") <> 1) or (rs("PRIVATE") = 1 and lcase(rs(strDBNTSQLNAME)) = lcase(strDBNTUSerName)) then%>
?? |
|
|
GauravBhabu
Advanced Member
4288 Posts |
Posted - 11 August 2002 : 09:02:38
|
Change the statement on Line 980 as below.
if EventRepeat(RS("EVENT_REPEAT"), strToDate(Rs("START_DATE")))then
|
CSS and HTML4.01 Compilant Snitz Forum . ForumSquare . Rakesh Jain
It is difficult to IMPROVE on Perfection, There is no harm in Keep Trying.
Prayer Of Forgiveness "I forgive all living beings. May all living beings forgive me! I cherish the friendliness towards all and harbour enmity towards none." -- Aavashyaka Sutra(Translated) |
|
|
macho
Junior Member
Denmark
150 Posts |
Posted - 11 August 2002 : 09:16:43
|
After changing that statement I now get this error msg:
Microsoft VBScript compilation error '800a03f9' Expected 'Then' events_functions.asp, line 980 if EventRepeat(RS("EVENT_REPEAT")), strToDate(Rs("START_DATE")))then ----------------------------------^
|
Edited by - macho on 11 August 2002 09:17:07 |
|
|
GauravBhabu
Advanced Member
4288 Posts |
Posted - 11 August 2002 : 09:19:22
|
You have an extra closing parentheses. Look at statement posted by me.
|
CSS and HTML4.01 Compilant Snitz Forum . ForumSquare . Rakesh Jain
It is difficult to IMPROVE on Perfection, There is no harm in Keep Trying.
Prayer Of Forgiveness "I forgive all living beings. May all living beings forgive me! I cherish the friendliness towards all and harbour enmity towards none." -- Aavashyaka Sutra(Translated) |
Edited by - GauravBhabu on 11 August 2002 09:20:46 |
|
|
macho
Junior Member
Denmark
150 Posts |
Posted - 11 August 2002 : 09:26:27
|
Okay, you're right, but after deleting that extra parenthese I get the "old" error msg again:
ADODB.Fields error '800a0cc1' Unknown runtime error events_functions.asp, line 980
|
|
|
GauravBhabu
Advanced Member
4288 Posts |
Posted - 11 August 2002 : 09:31:33
|
Let us do this. Replace tyhe statement on line 980 with the following
bln Repeat = EventRepeat(RS("event_repeat"), strToDate(Rs("start_date"))) if blnRepeat then
|
CSS and HTML4.01 Compilant Snitz Forum . ForumSquare . Rakesh Jain
It is difficult to IMPROVE on Perfection, There is no harm in Keep Trying.
Prayer Of Forgiveness "I forgive all living beings. May all living beings forgive me! I cherish the friendliness towards all and harbour enmity towards none." -- Aavashyaka Sutra(Translated) |
|
|
macho
Junior Member
Denmark
150 Posts |
Posted - 11 August 2002 : 09:38:46
|
Sorry to say: I replaced the statement but is still getting the same error msg?? |
|
|
GauravBhabu
Advanced Member
4288 Posts |
Posted - 11 August 2002 : 09:50:25
|
Replace the statements you added after do while as below. This is happening because the event_repeat column might not have any values for the earlier events.
intEventRepeat = Rs("Event_Repeat") if Rs("Event_Repeat") = "" then intEventRepeat = 0 blnRepeat = EventRepeat(intEventRepeat, strToDate(Rs("start_date"))) if blnRepeat then
|
CSS and HTML4.01 Compilant Snitz Forum . ForumSquare . Rakesh Jain
It is difficult to IMPROVE on Perfection, There is no harm in Keep Trying.
Prayer Of Forgiveness "I forgive all living beings. May all living beings forgive me! I cherish the friendliness towards all and harbour enmity towards none." -- Aavashyaka Sutra(Translated) |
Edited by - GauravBhabu on 11 August 2002 09:52:27 |
|
|
macho
Junior Member
Denmark
150 Posts |
Posted - 11 August 2002 : 10:02:59
|
It still gives me this error msg:
ADODB.Fields error '800a0cc1'
Unknown runtime error
events_functions.asp, line 980
Now I have the code looking like this (showing from line 978-985):
quote:
If NOT Rs.EOF Then Do While NOT Rs.EOF intEventRepeat = Rs("Event_Repeat") if Rs("Event_Repeat") = "" then intEventRepeat = 0 blnRepeat = EventRepeat(intEventRepeat, strToDate(Rs("start_date"))) if blnRepeat then if (rs("PRIVATE") <> 1) or (rs("PRIVATE") = 1 and lcase(rs(strDBNTSQLNAME)) = lcase(strDBNTUSerName)) then%> <br>
? |
|
|
GauravBhabu
Advanced Member
4288 Posts |
Posted - 11 August 2002 : 10:27:47
|
Add the following after do while statement and see what it prints.
Response.write "Repeat: " & Rs("Event_Repeat") Response.write :Start Date: " & Rs("start_date") Response.end
Have you added the function EventRepeat to event_functions.asp? |
CSS and HTML4.01 Compilant Snitz Forum . ForumSquare . Rakesh Jain
It is difficult to IMPROVE on Perfection, There is no harm in Keep Trying.
Prayer Of Forgiveness "I forgive all living beings. May all living beings forgive me! I cherish the friendliness towards all and harbour enmity towards none." -- Aavashyaka Sutra(Translated) |
|
|
macho
Junior Member
Denmark
150 Posts |
Posted - 11 August 2002 : 10:43:54
|
I'm getting the same error msg after the change:
ADODB.Fields error '800a0cc1'
Unknown runtime error
events_functions.asp, line 980
This is what it look like now (line 978-987):
Edit: removed
quote:
Have you added the function EventRepeat to event_functions.asp?
Yes, the function looks like this:
Call EventRepeat(Event_Repeat, Event_Date) if EventRepeat then Rem -Display the Event End if Function EventRepeat(intRepeat, DateIn) EventRepeat = False Select Case intRepeat Case 0 Rem -One Time Event if DateIn = Date then EventRepeat = True Case 1 Rem -Repeat Every Year if Month(DateIn) = Month(Date) and Day(DateIn) = Day(Date) then EventRepeat = True end if Case 2 Rem -Repeat Every Month if Day(DateIn) = Day(Date) then EventRepeat = True end if Case 3 Rem -Repeat Every Week if WeekDay(DateIn) = WeekDay(Date) then EventRepeat = True end if Case 4 Rem -Repeat Every Day EventRepeat = True End select End Function
|
Edited by - macho on 11 August 2002 13:44:12 |
|
|
GauravBhabu
Advanced Member
4288 Posts |
Posted - 11 August 2002 : 10:54:51
|
Have you added the field in the Database. |
CSS and HTML4.01 Compilant Snitz Forum . ForumSquare . Rakesh Jain
It is difficult to IMPROVE on Perfection, There is no harm in Keep Trying.
Prayer Of Forgiveness "I forgive all living beings. May all living beings forgive me! I cherish the friendliness towards all and harbour enmity towards none." -- Aavashyaka Sutra(Translated) |
|
|
macho
Junior Member
Denmark
150 Posts |
Posted - 11 August 2002 : 11:04:40
|
quote: Originally posted by GauravBhabu
Have you added the field in the Database.
Yes, it has been added, and when I check the database, after adding an event, it shows the correct Case, like "1" for Repeat Every Year, "2" for Repeat Every Month etc...
Can it be a problem with the properties of the field in the database?
|
|
|
GauravBhabu
Advanced Member
4288 Posts |
Posted - 11 August 2002 : 12:08:16
|
Do you have values in the Event_Repeat column for al events whether added new or old. |
CSS and HTML4.01 Compilant Snitz Forum . ForumSquare . Rakesh Jain
It is difficult to IMPROVE on Perfection, There is no harm in Keep Trying.
Prayer Of Forgiveness "I forgive all living beings. May all living beings forgive me! I cherish the friendliness towards all and harbour enmity towards none." -- Aavashyaka Sutra(Translated) |
|
|
Topic |
|