|
||
Stack Trace:
Version Information: Microsoft .NET Framework Version:1.1.4322.573; ASP.NET Version:1.1.4322.573 it is only temporay, it only happpens after the txt file has been made by using file.create() is there anything i can do to stop this error? Thanks Mart. ![]()
Mart |
Senior Member
Joined: 30 November 2002 Status: Offline Points: 2304
|
Post Options
Thanks(0)
Quote Reply
Posted: 23 September 2003 at 12:48pm
|
I am also getting this error:
Server Error in '/' Application.
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
Version Information: Microsoft .NET Framework Version:1.1.4322.573; ASP.NET Version:1.1.4322.573
Thanks, Mart.

Post Options
Thanks(0)
Quote
Reply
Posted: 23 September 2003 at 2:07pmFirst, try
If Dir(server.mappath("counters/" & request.QueryString("SID") & ".txt")) = Request.QueryString("SID") & ".txt" Then
Dim sReader As StreamReader = File.OpenText(server.mappath("counters/" & request.QueryString("SID") & ".txt"))
Dim sValue As String = sReader.ReadLine()
sReader.Close()
Return True
Else
Return False
End If
Now, this is in VB.NET, so no C#. If you really want C#, try and make this in C#, because it works in VB.NET like this.
BTW I colored it myself 

Post Options
Thanks(0)
Quote
Reply
Posted: 24 September 2003 at 12:41am
Post Options
Thanks(0)
Quote
Reply
Posted: 24 September 2003 at 4:45am
Post Options
Thanks(0)
Quote
Reply
Posted: 24 September 2003 at 4:46am
Post Options
Thanks(0)
Quote
Reply
Posted: 24 September 2003 at 9:10amIm not using C#! And i did close the writer.
mart.

Post Options
Thanks(0)
Quote
Reply
Posted: 24 September 2003 at 9:44am
Wh00ps, just a weird example from Microsoft how your pages SHOULD look like ... Well, why your code didn't work.. Maybe you had the textfile open in a reader or another proces (lol)? But anyway, if it works now, let's not worry to much.

Post Reply
|
Page 12> |
| Forum Jump | Forum Permissions ![]() You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |
|
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. |