Hi All
I have this ASP script.
and it works fine when i test it in IIS XP Pro, But when i run it on Windows 2003 server i get the following.
VBScript runtime error 800a0046
Permission Denied
Anyone have any ideas ?.
Thanks.
I have this ASP script.
Code:
<%
Dim objFSO, objCountFile
Dim iCount
Dim I
Set objFSO = Server.CreateObject("Scripting.FileSystemObject")
Set objCountFile = objFSO.OpenTextFile(Server.MapPath("counter.cnt"), 1, True)
If Not objCountFile.AtEndOfStream Then iCount = CLng(objCountFile.ReadAll) Else iCount = 0
objCountFile.Close
Set objCountFile = Nothing
iCount = iCount + 1
Set objCountFile = objFSO.CreateTextFile(Server.MapPath("counter.cnt"), True)
objCountFile.Write iCount
objCountFile.Close
' Write Counter to ASP
Set objCountFile = Nothing
Set objFSO = Nothing
Response.Write ("<CENTER><FONT STYLE='font-size:14xp;border:groove red 4px;color:red;background:white'>") & iCount & ("</FONT></CENTER>")
%>
and it works fine when i test it in IIS XP Pro, But when i run it on Windows 2003 server i get the following.
VBScript runtime error 800a0046
Permission Denied
Anyone have any ideas ?.
Thanks.