Unknown Error "Application timed out"??? 
Author Message
 Unknown Error "Application timed out"???

I am writing a large application which makes in Visual C++ (SDI app)
which makes use of MFC, a mix of ADO and CDatabase transactions
(CDatabase ones from older code and ADO in the newer code) and also
using a COM object which is installed as a service on my machine.

Some of the test sites that are running my application get an
"Application timed out" error on startup (before the user logs in).

Can anyone give me an indication and some examples of what might cause
this error to occur.  i have found no reference to this error after
several hours of searching on msdn, the web and newsgroups.

Thanks in advance

Andy :-)



Fri, 24 Jun 2005 14:53:21 GMT  
 Unknown Error "Application timed out"???
Both CDatabase and an ADO Connection have two separate timeout values that
can be set.  One is for login/connection.  This is the value that the
database will wait before deciding it will not be possible to establish a
connection to the database.  The other is for query/command.  This is the
amount of time a single (SQL) command can run without timing out.

For the login/connection, look at the following:
CDatabase::SetLoginTimeout(...), _ConnectionPtr::GetConnectionTimeout(...),
and _ConnectionPtr::SetConnectionTimeout.

For the query/command, take a look at the following:
CDatabase::SetQueryTimeout(..), _ConnectionPtr::GetCommandTimeout(...), and
_ConnectionPtr::SetCommandTimeout(...).

It sounds as of your problem comes at login/connection time when you are
first establishing your database connection.  This could be because of bad
connection parameters, a busy network, etc.

TFM3

Note: Spam-resistant e-mail address


Quote:
> I am writing a large application which makes in visual C++ (SDI app)
> which makes use of MFC, a mix of ADO and CDatabase transactions
> (CDatabase ones from older code and ADO in the newer code) and also
> using a COM object which is installed as a service on my machine.

> Some of the test sites that are running my application get an
> "Application timed out" error on startup (before the user logs in).

> Can anyone give me an indication and some examples of what might cause
> this error to occur.  i have found no reference to this error after
> several hours of searching on msdn, the web and newsgroups.

> Thanks in advance

> Andy :-)



Fri, 24 Jun 2005 16:46:55 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. RPC "Unknown protocol" error

2. "unknown size" error

3. WinSock function "connect" returns unknown error

4. "Unknown Error" from using GetHostByName

5. Error "free"-ing "malloc"-ed memory

6. "MSDEV.EXE Application Error"

7. CFileDialog gives "Application Error"

8. 16bit application error "Segment not present"

9. application error with "extern CMyApp theApp"

10. can't find "unknown.idl"

11. C# XsltContext for "unknown function" current()

12. Compile error "Internal error during SetupPhase"

 

 
Powered by phpBB® Forum Software