Forum Moderators: open

Message Too Old, No Replies

ASP Server Setup

Help with Cobalt server, Access DB, and ASP

         

Kenny_KUB

4:18 pm on Nov 21, 2001 (gmt 0)



[scottjordan.up-link.net...]

Hello all you smart peeps.

The link above is my problem. What is need to get ASP setup on a Cobalt server useing a MS Access database file?

Kenny the noob. (sorta)

sugarkane

4:33 pm on Nov 21, 2001 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Hi Kenny, welcome to wmw :)

Could you post a snippet of the code you're using? From the error message it looks like an SQL statement might be wrong somewhere.

Kenny_KUB

4:36 pm on Nov 21, 2001 (gmt 0)



Hey man wasup.
Thanks for helping first of all. And I love this place! :)

Ok here ya go.

<%
'----------General section------------

CURRENT_VERSION = ("2000")
CURRENT_STYLE = ("../ECStyle.css")
FormAction = ("Products.asp")
ScriptRelativeFolder = ("WebStore")
pos=InstrRev(LCase(Request.ServerVariables("PATH_TRANSLATED")),LCase(ScriptRelativeFolder) & "\" & LCase(FormAction))
BS_Root = Left(Request.ServerVariables("PATH_TRANSLATED"), pos-1 )
DB_Path =BS_Root & "\"
ScriptFolderAddress =BS_Root & "\" & ScriptRelativeFolder & "\"
URL =Request.ServerVariables("URL")
SERVER_NAME=Request.ServerVariables("SERVER_NAME")
ScriptAbsoluteUrl="http://"&SERVER_NAME&URL
ScriptRelativeFolder = ("WebStore")
pos=InstrRev(LCase(ScriptAbsoluteUrl),LCase(ScriptRelativeFolder) & "/" & LCase(FormAction))
BS_Root_URL = Left(ScriptAbsoluteUrl, pos-1)
CurrentFolder = BS_Root_URL &ScriptRelativeFolder& "/"
bHeaderFired = FALSE

'Enumeration Of Shipping Payment Methods
'==========Enumeration Of Payment Methods=============
FRSC = 1 'Flat rate shipping cost
CPI = 2 'Cost per item
FRPW = 3 'Fixed rate per weight (Kg or lb.)
POFS = 4 'Percentage of sales
'==========Constants=============
'---- CursorTypeEnum Values ----
Const adOpenForwardOnly = 0
Const adOpenKeyset = 1
Const adOpenDynamic = 2
Const adOpenStatic = 3

'---- LockTypeEnum Values ----
Const adLockReadOnly = 1
Const adLockPessimistic = 2
Const adLockOptimistic = 3
Const adLockBatchOptimistic = 4
'=========End of Section===========

'----------Parameters section------------
Parameter_36 = Request("productType")
if Request("productType")= "" Then
Parameter_36 = "0" 'Default value
else
if Request("productType").Count = 1 then
Parameter_36 = Request("productType")
end if
end if
Parameter_63 = Request("VisID")
if Request("VisID")= "" Then
Parameter_63 = "" 'Default value
else
if Request("VisID").Count = 1 then
Parameter_63 = Request("VisID")
end if
end if

Xoc

5:22 pm on Nov 21, 2001 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



The problem is in this line:

pos=InstrRev(LCase(Request.ServerVariables("PATH_TRANSLATED")),LCase(ScriptRelativeFolder) & "\" & LCase(FormAction))

The thing you are looking for isn't getting found. As such pos is set to 0. In the next line, that causes an error.

Kenny_KUB

5:37 pm on Nov 21, 2001 (gmt 0)



Since Im so new to ASP. Does anybody know what it is looking for? May then I can direct it to the right place.

One more thing, can ASP with a Access DB work on a Linix/UNIX server?