View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
b_r b_r is offline
external usenet poster
 
Posts: 2
Default Excel - Oracle database connection

Hi,

I have some problems!

- when I open the workbook I make oracle database connection:

Public Sub Workbook_Open()
Dim conOracle As ADODB.Connection
Set conOracle = New ADODB.Connection

conOracle.Open "DSN=db1; User ID=user; prompt = complete"
End Sub

- then in a normal module i run some macro and want to check if
connection is active

Sub Check_connection()
Dim conOracle As ADODB.Connection

check_con = conOracle.State