Hello Guys:
I am using the following code to read a text file. The problem is: when I have the
fileLocation set to a network path: The file Exists is always false. I know this
path is correct (I have verified this). However: if I move the MessageBoard.txt file
to the web-server and change the path to that file: the file is successfully found.
I checked the permissions on both files, and everyone is set to full control. Is
there something else I am missing?
--------------------------------------------------------------------------------
fileLocation = "\\B7HLN11\APAR\MessageBoard.txt"
Set objFSO = Server.CreateObject("Scripting.FileSystemObject")
If (objFSO.FileExists(fileLocation)) Then
Set objFile = objFSO.OpenTextFile(fileLocation, 1)
Do While Not objFile.AtEndOfStream
Line = objFile.ReadLine
If Line = BillingCycleMonth & "/" & BillingCycleYear Then
MessageBoard = objFile.ReadLine
Exit Do
End If
Loop
objFile.Close
Set objFile = Nothing
End If
Set objFSO = Nothing
--------------------------------------------------------------------------------
Thanks
Andy
------------------------ Yahoo! Groups Sponsor --------------------~-->
Yahoo! Domains - Claim yours for only $14.70
http://us.click.yahoo.com/Z1wmxD/DREIAA/yQLSAA/17folB/TM
--------------------------------------------------------------------~->
---------------------------------------------------------------------
Home : http://groups.yahoo.com/group/active-server-pages
---------------------------------------------------------------------
Post : [EMAIL PROTECTED]
Subscribe : [EMAIL PROTECTED]
Unsubscribe: [EMAIL PROTECTED]
---------------------------------------------------------------------
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/active-server-pages/
<*> To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/