|
-
April 21st, 1999, 10:13 AM
#1
CDatabase causes a "Select Data Source" dialog Box ...
I've written a background MFC program that wakes up on a timer message and looks for files in a specified directory. If present, the files get processed and results are inserted into a DB/2 table via an ODBC connnection. I'm doing the ODBC via CDatabase. The DB/2 server is located on another computer on our LAN. Problem is that occasionally, the DB/2 server is not available (crashed, etc). When this happens, my attempt to open the connection (CDatabase::OpenEx()) causes a Select ODBC data source dialog box to pop up and everything waits for a user to select a source and continue. I am using the following code:
if (!dTemp->IsOpen()) {
try {
dTemp->OpenEx(TICKERDSN,CDatabase::noOdbcDialog);
}
catch (CDBException * e) { ...}
}
Any thoughts??
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|