By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
440,830 Members | 812 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 440,830 IT Pros & Developers. It's quick & easy.

ERROR - no error information available

P: n/a
Hi,

I using this code, to connect with a paradox file with ASP.NET. The first
time its connect ok, but others times occurs the error:

"ERROR - no error information available"

I close all connection, and this error yet occurs.

Someone knows why this ?

Thanks,
Ricardo
Connection strirng content:
==================

"Driver={Microsoft Paradox Driver (*.db )};DriverID=538;Fil=Paradox
5.X;DefaultDir=c:\inetpub\wwwroot\fafire\web\gradu acao_pagamento\dados\;Dbq=c:\inetpub\wwwroot\fafir e\web\graduacao_pagamento\dados\;CollatingSequence =ASCII"

Code executed when the button is clicked
============================
Private Sub CustomValidator1_ServerValidate(ByVal source As System.Object,
ByVal args As System.Web.UI.WebControls.ServerValidateEventArgs) Handles
CustomValidator1.ServerValidate

Dim PathAux As String = Server.MapPath("Web.config")
Dim PathRoot As String = PathAux.Substring(0,
PathAux.IndexOf("Web.config"))
Dim PastaDados As String = "BD" & Session("ano") &
Session("semestre")

Dim strConString As String = "Driver={Microsoft Paradox Driver
(*.db )};" & _
"DriverID=538;" & _
"Fil=Paradox 5.X;" & _
"DefaultDir=" & PathRoot & "dados\;" & _
"Dbq=" & PathRoot & "dados\;" & _
"CollatingSequence=ASCII"
Dim objConn As New Odbc.OdbcConnection(strConString)
Dim objCmd As New Odbc.OdbcCommand
Dim objDr As Odbc.OdbcDataReader

Try
objConn.Close()
objConn.Open()
objCmd.Connection = objConn
'================================================= ======================
' Validando Matricula e CPF
'================================================= ======================
objCmd.CommandType = CommandType.Text
objCmd.CommandText = "select
a.alu_nome,a.alu_end,a.alu_num,a.alu_compl,a.alu_b ai,a.alu_cid,a.alu_est,
a.alu_cep,d.cus_cod,d.cus_nome from ALU20052 as a, MAT20052 as c, cursos as
d where c.mat_alun = '" & Trim(txtNrMatr.Text) & "' and a.alu_cpf = '" &
Trim(txtNrCPF.Text) & "' and c.mat_alun = a.alu_matr and a.alu_cur =
d.cus_cod"
objDr = objCmd.ExecuteReader(CommandBehavior.CloseConnecti on)
If objDr.Read Then ' Matricula VŠlida
Session("alu_nome") = Trim(objDr("alu_nome"))
Session("mat_alun") = Trim(txtNrMatr.Text)
Session("alun_cpf") = Trim(txtNrCPF.Text)
Session("alu_end") =
Trim(oFafire.validaDRText(objDr("alu_end")))
Session("alu_num") =
Trim(oFafire.validaDRText(objDr("alu_num")))
Session("alu_compl") =
Trim(oFafire.validaDRText(objDr("alu_compl")))
Session("alu_bai") =
Trim(oFafire.validaDRText(objDr("alu_bai")))
Session("alu_cid") =
Trim(oFafire.validaDRText(objDr("alu_cid")))
Session("alu_est") =
Trim(oFafire.validaDRText(objDr("alu_est")))
Session("alu_cep") =
IIf(Trim(oFafire.validaDRText(objDr("alu_cep"))) = "", "50000-000",
Trim(oFafire.validaDRText(objDr("alu_cep"))))
Session("cus_nome") = Trim(objDr("cus_nome"))
args.IsValid = True
Else ' Matricula InvŠlida
CustomValidator1.ErrorMessage = "Matricula/CPF Incorreto"
args.IsValid = False
End If

Catch ex As System.Exception
args.IsValid = False
Response.Redirect("error.aspx?MensagemTexto=" & ex.Message.Trim
& "&MensagemPaginaRetorno=mensalidade_pagamento_entr ada.aspx", False)

Finally
If objConn.State = ConnectionState.Open Then objConn.Close()
objConn.Dispose()
objCmd.Dispose()
If Not IsNothing(objDr) Then objDr.Close()
objDr = Nothing
End Try

End Sub

Nov 19 '05 #1
Share this Question
Share on Google+
2 Replies


P: n/a
Funny .. with "No Error Information" it is kinda impossible to tell exactly
what is going wrong .. except .. that error is definitely occurring outside
of .NET i..e inside your Odbc driver.

- Sahil Malik [MVP]
ADO.NET 2.0 book -
http://codebetter.com/blogs/sahil.ma.../13/63199.aspx
----------------------------------------------------------------------------
---------------

"Ricardo Magalh„es" <ri*********@hotmail.com> wrote in message
news:#0**************@TK2MSFTNGP10.phx.gbl...
Hi,

I using this code, to connect with a paradox file with ASP.NET. The first
time its connect ok, but others times occurs the error:

"ERROR - no error information available"

I close all connection, and this error yet occurs.

Someone knows why this ?

Thanks,
Ricardo
Connection strirng content:
==================

"Driver={Microsoft Paradox Driver (*.db )};DriverID=538;Fil=Paradox
5.X;DefaultDir=c:\inetpub\wwwroot\fafire\web\gradu acao_pagamento\dados\;Dbq=
c:\inetpub\wwwroot\fafire\web\graduacao_pagamento\ dados\;CollatingSequence=A
SCII"
Code executed when the button is clicked
============================
Private Sub CustomValidator1_ServerValidate(ByVal source As System.Object, ByVal args As System.Web.UI.WebControls.ServerValidateEventArgs) Handles
CustomValidator1.ServerValidate

Dim PathAux As String = Server.MapPath("Web.config")
Dim PathRoot As String = PathAux.Substring(0,
PathAux.IndexOf("Web.config"))
Dim PastaDados As String = "BD" & Session("ano") &
Session("semestre")

Dim strConString As String = "Driver={Microsoft Paradox Driver
(*.db )};" & _
"DriverID=538;" & _
"Fil=Paradox 5.X;" & _
"DefaultDir=" & PathRoot & "dados\;" & _ "Dbq=" & PathRoot & "dados\;" & _
"CollatingSequence=ASCII"
Dim objConn As New Odbc.OdbcConnection(strConString)
Dim objCmd As New Odbc.OdbcCommand
Dim objDr As Odbc.OdbcDataReader

Try
objConn.Close()
objConn.Open()
objCmd.Connection = objConn
'================================================= ====================== ' Validando Matricula e CPF
'================================================= ====================== objCmd.CommandType = CommandType.Text
objCmd.CommandText = "select
a.alu_nome,a.alu_end,a.alu_num,a.alu_compl,a.alu_b ai,a.alu_cid,a.alu_est,
a.alu_cep,d.cus_cod,d.cus_nome from ALU20052 as a, MAT20052 as c, cursos as d where c.mat_alun = '" & Trim(txtNrMatr.Text) & "' and a.alu_cpf = '" &
Trim(txtNrCPF.Text) & "' and c.mat_alun = a.alu_matr and a.alu_cur =
d.cus_cod"
objDr = objCmd.ExecuteReader(CommandBehavior.CloseConnecti on)
If objDr.Read Then ' Matricula VŠlida
Session("alu_nome") = Trim(objDr("alu_nome"))
Session("mat_alun") = Trim(txtNrMatr.Text)
Session("alun_cpf") = Trim(txtNrCPF.Text)
Session("alu_end") =
Trim(oFafire.validaDRText(objDr("alu_end")))
Session("alu_num") =
Trim(oFafire.validaDRText(objDr("alu_num")))
Session("alu_compl") =
Trim(oFafire.validaDRText(objDr("alu_compl")))
Session("alu_bai") =
Trim(oFafire.validaDRText(objDr("alu_bai")))
Session("alu_cid") =
Trim(oFafire.validaDRText(objDr("alu_cid")))
Session("alu_est") =
Trim(oFafire.validaDRText(objDr("alu_est")))
Session("alu_cep") =
IIf(Trim(oFafire.validaDRText(objDr("alu_cep"))) = "", "50000-000",
Trim(oFafire.validaDRText(objDr("alu_cep"))))
Session("cus_nome") = Trim(objDr("cus_nome"))
args.IsValid = True
Else ' Matricula InvŠlida
CustomValidator1.ErrorMessage = "Matricula/CPF Incorreto"
args.IsValid = False
End If

Catch ex As System.Exception
args.IsValid = False
Response.Redirect("error.aspx?MensagemTexto=" & ex.Message.Trim & "&MensagemPaginaRetorno=mensalidade_pagamento_entr ada.aspx", False)

Finally
If objConn.State = ConnectionState.Open Then objConn.Close()
objConn.Dispose()
objCmd.Dispose()
If Not IsNothing(objDr) Then objDr.Close()
objDr = Nothing
End Try

End Sub

Nov 19 '05 #2

P: n/a
Hi Ricardo.

I understood that the connecrion is going ok, but at some isam drivers, the
connection only occurs when the real table is accessed.

So the problem still could be connection string, if you cant make a sql
"select" on a table.

I suggest you to create a file with "udl" extension on your desktop, then
double click
on the icon to configure the connection string to the paradox folder.

Wil be shown the properties to connect via paradox to the tables.
Configure all options needed and confirm to save and close.

Edit the file with nodepad and compare the connection string with the ADO.Net
connection string. Maybe with this you can detect any problem on your
connection string.

Fabio dos Santos Fernandes
MCAD.Net
WiseNetworks tecnologia
www.wisenetworks.com.br
Cause

"Ricardo Magalh√£es" escreveu:
Hi,

I using this code, to connect with a paradox file with ASP.NET. The first
time its connect ok, but others times occurs the error:

"ERROR - no error information available"

I close all connection, and this error yet occurs.

Someone knows why this ?

Thanks,
Ricardo
Connection strirng content:
==================

"Driver={Microsoft Paradox Driver (*.db )};DriverID=538;Fil=Paradox
5.X;DefaultDir=c:\inetpub\wwwroot\fafire\web\gradu acao_pagamento\dados\;Dbq=c:\inetpub\wwwroot\fafir e\web\graduacao_pagamento\dados\;CollatingSequence =ASCII"

Code executed when the button is clicked
============================
Private Sub CustomValidator1_ServerValidate(ByVal source As System.Object,
ByVal args As System.Web.UI.WebControls.ServerValidateEventArgs) Handles
CustomValidator1.ServerValidate

Dim PathAux As String = Server.MapPath("Web.config")
Dim PathRoot As String = PathAux.Substring(0,
PathAux.IndexOf("Web.config"))
Dim PastaDados As String = "BD" & Session("ano") &
Session("semestre")

Dim strConString As String = "Driver={Microsoft Paradox Driver
(*.db )};" & _
"DriverID=538;" & _
"Fil=Paradox 5.X;" & _
"DefaultDir=" & PathRoot & "dados\;" & _
"Dbq=" & PathRoot & "dados\;" & _
"CollatingSequence=ASCII"
Dim objConn As New Odbc.OdbcConnection(strConString)
Dim objCmd As New Odbc.OdbcCommand
Dim objDr As Odbc.OdbcDataReader

Try
objConn.Close()
objConn.Open()
objCmd.Connection = objConn
'================================================= ======================
' Validando Matricula e CPF
'================================================= ======================
objCmd.CommandType = CommandType.Text
objCmd.CommandText = "select
a.alu_nome,a.alu_end,a.alu_num,a.alu_compl,a.alu_b ai,a.alu_cid,a.alu_est,
a.alu_cep,d.cus_cod,d.cus_nome from ALU20052 as a, MAT20052 as c, cursos as
d where c.mat_alun = '" & Trim(txtNrMatr.Text) & "' and a.alu_cpf = '" &
Trim(txtNrCPF.Text) & "' and c.mat_alun = a.alu_matr and a.alu_cur =
d.cus_cod"
objDr = objCmd.ExecuteReader(CommandBehavior.CloseConnecti on)
If objDr.Read Then ' Matricula V√°lida
Session("alu_nome") = Trim(objDr("alu_nome"))
Session("mat_alun") = Trim(txtNrMatr.Text)
Session("alun_cpf") = Trim(txtNrCPF.Text)
Session("alu_end") =
Trim(oFafire.validaDRText(objDr("alu_end")))
Session("alu_num") =
Trim(oFafire.validaDRText(objDr("alu_num")))
Session("alu_compl") =
Trim(oFafire.validaDRText(objDr("alu_compl")))
Session("alu_bai") =
Trim(oFafire.validaDRText(objDr("alu_bai")))
Session("alu_cid") =
Trim(oFafire.validaDRText(objDr("alu_cid")))
Session("alu_est") =
Trim(oFafire.validaDRText(objDr("alu_est")))
Session("alu_cep") =
IIf(Trim(oFafire.validaDRText(objDr("alu_cep"))) = "", "50000-000",
Trim(oFafire.validaDRText(objDr("alu_cep"))))
Session("cus_nome") = Trim(objDr("cus_nome"))
args.IsValid = True
Else ' Matricula Inv√°lida
CustomValidator1.ErrorMessage = "Matricula/CPF Incorreto"
args.IsValid = False
End If

Catch ex As System.Exception
args.IsValid = False
Response.Redirect("error.aspx?MensagemTexto=" & ex.Message.Trim
& "&MensagemPaginaRetorno=mensalidade_pagamento_entr ada.aspx", False)

Finally
If objConn.State = ConnectionState.Open Then objConn.Close()
objConn.Dispose()
objCmd.Dispose()
If Not IsNothing(objDr) Then objDr.Close()
objDr = Nothing
End Try

End Sub

Nov 19 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.