Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 16
Default Tough one - Timeout doesn't work

Hi

I send data from Excel to database with ADO connection.

Sometimes other users with other programs use the database, and reserve
access.

I need to define timeout parameter for the ADO connection, so it doesn't
hang and wait forever if the database is in use by somebody else.

I've tried several options:

--------------

Dim conn As New ADODB.Connection
conn.ConnectionTimeout = 5
conn.CommandTimeout = 5

Dim cmdSQLData As ADODB.Command
Set cmdSQLData = New ADODB.Command
cmdSQLData.CommandTimeout = 5

--------------

Nothing works. It doesn't give error after 5 seconds, but hangs and waits
until the database access is released by another program.

Please help!!

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
ole timeout Jean-Daniel Perroset Excel Programming 1 January 7th 09 09:18 AM
Ole timeout [email protected] Excel Programming 0 November 11th 08 12:28 PM
timeout on GetSaveAs? msteiert Excel Programming 3 December 13th 05 02:27 AM
TImeIn-TimeOut-TimeIn-TimeOut-HoursWorked ChefBoiRD Excel Worksheet Functions 3 September 20th 05 10:01 AM
Timeout tcbootneck Excel Programming 1 July 15th 05 11:48 AM


All times are GMT +1. The time now is 10:26 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"