Snitz Forums 2000
Snitz Forums 2000
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 Snitz Forums 2000 MOD-Group
 MOD Add-On Forum (W/O Code)
 How do I make events recurring (cont.)
 New Topic  Topic Locked
 Printer Friendly
Previous Page | Next Page
Author Previous Topic Topic Next Topic
Page: of 5

GauravBhabu
Advanced Member

4288 Posts

Posted - 11 August 2002 :  07:40:26  Show Profile
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)
Go to Top of Page

macho
Junior Member

Denmark
150 Posts

Posted - 11 August 2002 :  08:01:16  Show Profile
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%>



??
Go to Top of Page

GauravBhabu
Advanced Member

4288 Posts

Posted - 11 August 2002 :  09:02:38  Show Profile
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)
Go to Top of Page

macho
Junior Member

Denmark
150 Posts

Posted - 11 August 2002 :  09:16:43  Show Profile
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
Go to Top of Page

GauravBhabu
Advanced Member

4288 Posts

Posted - 11 August 2002 :  09:19:22  Show Profile
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
Go to Top of Page

macho
Junior Member

Denmark
150 Posts

Posted - 11 August 2002 :  09:26:27  Show Profile
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
Go to Top of Page

GauravBhabu
Advanced Member

4288 Posts

Posted - 11 August 2002 :  09:31:33  Show Profile
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)
Go to Top of Page

macho
Junior Member

Denmark
150 Posts

Posted - 11 August 2002 :  09:38:46  Show Profile
Sorry to say: I replaced the statement but is still getting the same error msg??
Go to Top of Page

GauravBhabu
Advanced Member

4288 Posts

Posted - 11 August 2002 :  09:50:25  Show Profile
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
Go to Top of Page

macho
Junior Member

Denmark
150 Posts

Posted - 11 August 2002 :  10:02:59  Show Profile
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>



?
Go to Top of Page

GauravBhabu
Advanced Member

4288 Posts

Posted - 11 August 2002 :  10:27:47  Show Profile
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)
Go to Top of Page

macho
Junior Member

Denmark
150 Posts

Posted - 11 August 2002 :  10:43:54  Show Profile
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
Go to Top of Page

GauravBhabu
Advanced Member

4288 Posts

Posted - 11 August 2002 :  10:54:51  Show Profile
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)
Go to Top of Page

macho
Junior Member

Denmark
150 Posts

Posted - 11 August 2002 :  11:04:40  Show Profile
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?
Go to Top of Page

GauravBhabu
Advanced Member

4288 Posts

Posted - 11 August 2002 :  12:08:16  Show Profile
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)
Go to Top of Page
Page: of 5 Previous Topic Topic Next Topic  
Previous Page | Next Page
 New Topic  Topic Locked
 Printer Friendly
Jump To:
Snitz Forums 2000 © 2000-2021 Snitz™ Communications Go To Top Of Page
This page was generated in 0.24 seconds. Powered By: Snitz Forums 2000 Version 3.4.07