Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: ODBC Disconnect
This is using the ODBC API...
Function DisconnectFromDatasource(hdbc As Long, hstmt As Long) As Integer
'Function Returns False if any API call fails; True otherwise
Dim Result As Integer
On Error GoTo DisconnectFromDatasource_Error
DisconnectFromDatasource = True
'statement handle
If hstmt <> 0 Then
Result = SQLFreeStmt(ByVal hstmt, SQL_DROP) hstmt = 0 If Result <> SQL_SUCCESS Then DisconnectFromDatasource = FalseEnd If
Result = SQLDisconnect(ByVal hdbc) If Result <> SQL_SUCCESS Then DisconnectFromDatasource = FalseEnd If
Result = SQLFreeConnect(ByVal hdbc) If Result <> SQL_SUCCESS Then DisconnectFromDatasource = FalseEnd If
DisconnectFromDatasource_Error:
DisplayErrorMessage "DisconnectFromDatasource", "ODBCVB.Bas" Resume Next
End Function
Paul.
davehall_at_umich.edu wrote in article <868896124.6886_at_dejanews.com>...
> I need some major help. How do you diconnect from a ORACLE ODBC Driver
> from VB 4.0 without restarting the entire program.
>
> Dave Hall
>
> -------------------==== Posted via Deja News ====-----------------------
> http://www.dejanews.com/ Search, Read, Post to Usenet
>
Received on Thu Jul 17 1997 - 00:00:00 CDT
![]() |
![]() |