Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
jhun_garma
Starting Member
15 Posts |
Posted - 2002-03-12 : 21:58:10
|
| i have an application that connects to an sql 2k server via internet.my problems is i want to trap an error "general network error". since everytime i get this error the system crashes. this occurs everytime the application loses its connection. any suggestions on how to do it in vb6many thanks in advancejhun |
|
|
rrb
SQLTeam Poet Laureate
1479 Posts |
Posted - 2002-03-12 : 23:40:28
|
jhun_garmaa couple of questions...quote: i have an application that connects to an sql 2k server via internet.
Do you mean ASP? Or do you mean you're connecting to some server which is not at your site via TCP/IP?quote: since everytime i get this error the system crashes.
When you say the system crashes, do you mean your ASP page? SQL Server? IIS Server? Network?--I hope that when I die someone will say of me "That guy sure owed me a lot of money" |
 |
|
|
jhun_garma
Starting Member
15 Posts |
Posted - 2002-03-12 : 23:46:09
|
| a visual basic application using tcp/ip. the program crashes thats why i need to trap itthanks jhun |
 |
|
|
rrb
SQLTeam Poet Laureate
1479 Posts |
Posted - 2002-03-12 : 23:59:50
|
quote: a visual basic application using tcp/ip. the program crashes thats why i need to trap it
And Public Sub Connect()On error goto Err_SubDim db as NEw ADODB.Connectiondb.Open sProviderdb.CloseSet db = NothingExit SubErr_Sub:MsgBox "Error"End SubDoesn't catch the error?--I hope that when I die someone will say of me "That guy sure owed me a lot of money"Edited by - rrb on 03/13/2002 00:14:47 |
 |
|
|
byrmol
Shed Building SQL Farmer
1591 Posts |
Posted - 2002-03-13 : 00:18:44
|
jhun,Have you had a look at the events associated with the connection object?eg..'Module or class declaration'Connection InstancePrivate WithEvents mCNN As ADODB.Connection Then have a look a the methods for its event...I think you are after "Disconnect" or "InfoMessage"...HTHDavidMTomorrow is the same day as Today was the day before. |
 |
|
|
|
|
|