Luc
Well-known member
- Joined
- Nov 29, 2005
- Messages
- 59
- Programming Experience
- 1-3
I'm new to asp.net 2.0 and I'm trying to make a simple newspage wich can be changed by changing a textdocument, the code goes as following:
However I keep getting a stack overflow exception at the line containing
Dim sr As New
I checked the link and its valid. Anny help?
VB.NET:
Partial Class _Default
Inherits System.Web.UI.Page
Dim logged_in As Boolean = False
Dim first As Boolean = True
Dim wc As New System.Net.WebClient()
Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
lblNews.Text = ""
txtlogged.Text = "Not logged in"
txtlogged.ForeColor = Drawing.Color.Red
Dim sr As New System.IO.StreamReader(wc.OpenRead("http://users.skynet.be/fa588483/news.txt"))
Dim line$
Do
line = sr.ReadLine
If Not line Is Nothing Then lblnews.Text &= line & "<br>"
Loop Until line Is Nothing
sr.Close()
If first Then
txtlogged.Text = "Not logged in"
txtlogged.ForeColor = Drawing.Color.Red
first = False
transfer_login()
End If
End Sub
However I keep getting a stack overflow exception at the line containing
Dim sr As New
VB.NET:
System.IO.StreamReader(wc.OpenRead("http://users.skynet.be/fa588483/news.txt")