Click to See Complete Forum and Search --> : ASP.net quirks AHHHHH!


PeOfEo
02-17-2003, 12:50 AM
What the heck is with the quirks in this language? Go to http://www12.brinkster.com/knightsempire/db/index.aspx You will have to make a new account, but try to post on the message board... I dare you. Too bad you cant. Well somtimes you can but the darned pages dont ever load completly ARG. The dont display like the title will be there and the background and the scroll board but thats it. Is this just some asp.net quirk that I cant do anything about? Or is there a remedy for this foul menace. I really hate it when you get the random debugger error thingy when it say uncarried out task or some other lame thing. ITS DRIVING MY NUTS!

PeOfEo
02-17-2003, 02:34 AM
weird. I reuploaded the data base with a new enter message on the forum talking about the quirks and now they are gone AHHHHHHH. Oh well. Well thats still very weird and I wanna know what was making that happen

PeOfEo
02-17-2003, 04:40 AM
Sub SubmitBtn_Click(Sender As Object, E As EventArgs)
Dim DBConn as OleDbConnection
Dim DBCommand As OleDbDataAdapter
Dim DSLogin as New DataSet
Dim DBInsert As New OleDbCommand
DBConn = New OleDbConnection("PROVIDER=Microsoft.Jet.OLEDB.4.0;" _
& "DATA SOURCE=" _
& Server.MapPath("/knightsempire/db/" _
& "C7messageboard.mdb;"))
DBCommand = New OleDbDataAdapter _
("Select Count(MemberID) as TheCount " _
& "from Members Where " _
& "MemberName = '" & txtMemberName.Text _
& "'", DBConn)
MY ERROR MESSAGE IS HERE --> DBCommand.Fill(DSLogin, _
"TheCount")
If DSLogin.Tables("TheCount").Rows(0).Item("TheCount") = 0 Then
DBInsert.CommandText = "Insert Into Members " _
& "(MemberName, [Password], EmailAddress) " _
& "values (" _
& "'" & Replace(txtMemberName.text, "'", "''") & "', " _
& "'" & Replace(txtPassword.text, "'", "''") & "', " _
& "'" & Replace(txtEmailAddress.text, "'", "''") & "')"

I just dont understand this error. I check the book I have been using since htis is the book's forum with heavy modification and these scripts are the same. Also This error is completly random and unpredictable about when you will get it. I just tried to log in and check and got it... ten times I tried too, then I posted this then clicked the link in my signiture and sure enough it worked again. Its driving me nuts. It affects both my log in and my register page but I cant find a shread of bad code on my index. What the heck do you think is going on?

Ribeyed
02-17-2003, 12:14 PM
hi,
yes i got the error as well. When you do your SQL count statement there is at least 1 record in the database?
If there is not then that is your problem.
The erro is showing on line 21:
If DSLogin.Tables("TheCount").Rows(1).Item("TheCount") = 0 Then
also this line if slightly different from the one your posted:
If DSLogin.Tables("TheCount").Rows(0).Item("TheCount") = 0 Then

PeOfEo
02-17-2003, 04:14 PM
well I changed that to a 1 just to see if it did anything but my error is in the post above and it is very annoying. I have a bunch of records in the data base so I have no Idea why it is doing that but It sure is annoying because no one can use the forum when that heppens. Half the time when you can log in the page does not load, I just dont get it. Is asp.net just a quirky language or am I doing something wrong? i want a forum like this one... and when I say like this one I mean one without a bunch of errors

PeOfEo
02-17-2003, 04:57 PM
Ok I changed that 1 back to a 0 but I still have the original error. Its in the log in and register pages. Also now may pages wont load properly again BLARGHHH:mad: