Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Count hits with ASP code?
Message
General information
Forum:
Internet
Category:
Active Server Page
Miscellaneous
Thread ID:
00322578
Message ID:
00329984
Views:
27
I am new at this and I have hard time finding the right documantation for what I want to. Now I know that I need to create a connection first and then create a recordset. But where can I find the right Connect string for a foxpro table.

Do I need to setup a OLDB drive on my server?

My code like like this:
Set oCon = Server.CreateObject("ADODB.Connection")
ConnStr= "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=PageCnt.dbf;Extended Properties=dBASE III;" 
oCon.Open ConnStr
set oRec = Server.CreateObject("ADODB.RecordSet")
' on error resume next
sql="SELECT * FROM PAGECNT WHERE PAGEID='MINUTES'"
oRec.Open sql,oCon,adOpenDynamic,adLockPessimistic
HitSince=cstr(oRec("Firstdate"))
HitCount=cdbl(oRec("HitCount"))+1
oRec("HitCount")=HitCount
oRec("Lastdate")=cstr(date)

oRec.Update
oRec.Close
If err.number<>0 then
   HitCount=0
   err.clear
   Response.Redirect("default.asp")
end if   
Previous
Reply
Map
View

Click here to load this message in the networking platform