Web Wiz - Green Windows Web Hosting

  New Posts New Posts RSS Feed - Today in History Script.
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Today in History Script.

 Post Reply Post Reply Page  123 5>
Author
davidshq View Drop Down
Senior Member
Senior Member


Joined: 29 July 2003
Location: United States
Status: Offline
Points: 299
Post Options Post Options   Thanks (0) Thanks(0)   Quote davidshq Quote  Post ReplyReply Direct Link To This Post Topic: Today in History Script.
    Posted: 23 October 2003 at 3:42pm

Hi Folks,
  I was wondering if anyone knew of a Today in History ASP script that was free?

Respectfully,
David Mackey
- www.civilwarsearch.com

Back to Top
michael View Drop Down
Senior Member
Senior Member
Avatar

Joined: 08 April 2002
Location: United States
Status: Offline
Points: 4670
Post Options Post Options   Thanks (0) Thanks(0)   Quote michael Quote  Post ReplyReply Direct Link To This Post Posted: 23 October 2003 at 5:05pm
The script is not the problem, the problem woulf be having the database behind it...
Back to Top
davidshq View Drop Down
Senior Member
Senior Member


Joined: 29 July 2003
Location: United States
Status: Offline
Points: 299
Post Options Post Options   Thanks (0) Thanks(0)   Quote davidshq Quote  Post ReplyReply Direct Link To This Post Posted: 23 October 2003 at 8:24pm

Michael,
   Can you explain why the database would be a problem? Or do you mean the fact that you would need to fill it with facts?
   I am working on design a TiH script now.

Respectfully,
David Mackey.
- www.civilwarsearch.com

Back to Top
davidshq View Drop Down
Senior Member
Senior Member


Joined: 29 July 2003
Location: United States
Status: Offline
Points: 299
Post Options Post Options   Thanks (0) Thanks(0)   Quote davidshq Quote  Post ReplyReply Direct Link To This Post Posted: 23 October 2003 at 8:58pm

Hi Folks,
  Check out what I have completed so far at www.dhq.nu/tdih/todayinhistory.asp.
  Here is the source:

' David Mackey's Today in History ASP Script.

<%

' Variables.

Dim adoConn

Dim rsToday

Dim strSQL

Set adoConn = Server.CreateObject("ADODB.Connection")

adoConn.Open "DRIVER={Microsoft Access Driver (*.mdb)}; DBQ=" & Server.MapPath("civilwar.mdb")

strSQL="SELECT tblToday.Year, tblToday.Event Where tblToday.Month = month(date) and tblToday.Day = day(date)"

rsToday.Open strSQL, adoConn

Do While Not rsToday.EOF

Response.Write(rsToday("Month"))

Response.Write(rsToday("Day"))

Response.Write(rsToday("Year"))

Response.Write(rsToday("Event"))

rsToday.MoveNext

Loop

rsToday.Close

Set rsToday = Nothing

Set adoConn = Nothing

%>

Of course it doesn't work...Any help would be appreciated. :-)

Respectfully,

David.

Back to Top
dpyers View Drop Down
Senior Member
Senior Member


Joined: 12 May 2003
Status: Offline
Points: 3937
Post Options Post Options   Thanks (0) Thanks(0)   Quote dpyers Quote  Post ReplyReply Direct Link To This Post Posted: 24 October 2003 at 12:22am
' David Mackey's Today in History ASP Script.

Microsoft VBScript runtime error '800a01a8'

Object required: ''

/tdih/todayinhistory.asp, line 12


Lead me not into temptation... I know the short cut, follow me.
Back to Top
WebWiz-Bruce View Drop Down
Admin Group
Admin Group
Avatar
Web Wiz Developer

Joined: 03 September 2001
Location: Bournemouth
Status: Offline
Points: 9844
Post Options Post Options   Thanks (0) Thanks(0)   Quote WebWiz-Bruce Quote  Post ReplyReply Direct Link To This Post Posted: 24 October 2003 at 1:51am
Which line is line 12???
Back to Top
davidshq View Drop Down
Senior Member
Senior Member


Joined: 29 July 2003
Location: United States
Status: Offline
Points: 299
Post Options Post Options   Thanks (0) Thanks(0)   Quote davidshq Quote  Post ReplyReply Direct Link To This Post Posted: 24 October 2003 at 6:18am

Line 12 is

rsToday.Open strSQL, adoConn

I believe. It probably has to do with my SQL statement.
Respectfully,
David Mackey.

- www.civilwarsearch.com

Back to Top
davidshq View Drop Down
Senior Member
Senior Member


Joined: 29 July 2003
Location: United States
Status: Offline
Points: 299
Post Options Post Options   Thanks (0) Thanks(0)   Quote davidshq Quote  Post ReplyReply Direct Link To This Post Posted: 24 October 2003 at 6:25am
Here is the newest code I have written:
(Still not functioning)

<%
' Variables.
Dim adoConn
Dim rsToday
Dim strSQL

Set adoConn = Server.CreateObject("ADODB.Connection")
adoConn.Open "DRIVER={Microsoft Access Driver (*.mdb)}; DBQ=" & Server.MapPath("civilwar.mdb")
strSQL="SELECT tblToday.mYear, tblToday.mEvent, tblToday.mMonth, tblToday.mDay Where tblToday.mMonth =" & month(date) & "tblToday.mDay =" & day(date)

rsToday.Open strSQL, adoConn
Do While Not rsToday.EOF
Response.Write(rsToday("mMonth"))
Response.Write(rsToday("mDay"))
Response.Write(rsToday("mYear"))
Response.Write(rsToday("mEvent"))
rsToday.MoveNext

Loop

rsToday.Close
Set rsToday = Nothing
Set adoConn = Nothing

%>
Respectfully,
David Mackey.

Back to Top
 Post Reply Post Reply Page  123 5>

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.08
Copyright ©2001-2026 Web Wiz Ltd.


Become a Fan on Facebook Follow us on X Connect with us on LinkedIn Web Wiz Blogs
About Web Wiz | Contact Web Wiz | Terms & Conditions | Cookies | Privacy Notice

Web Wiz is the trading name of Web Wiz Ltd. Company registration No. 05977755. Registered in England and Wales.
Registered office: Web Wiz Ltd, Unit 18, The Glenmore Centre, Fancy Road, Poole, Dorset, BH12 4FB, UK.

Prices exclude VAT at 20% unless otherwise stated. VAT No. GB988999105 - $, € prices shown as a guideline only.

Copyright ©2001-2026 Web Wiz Ltd. All rights reserved.