CDaoDatabase Open()

When i try to open a database i get no errors however when i run the program i get an error "Couldn't find file 'FileName'" I checked and it occurs because of line 42 in daocore.cpp. The thing i don't understand is that the file path is correct and the file is there, so why can't the program find it? Here's my code:

CDaoDatabase (m_pDAOWorkspace);
CDaoDatabase database;
try {
database.Open("C:\Documents and Settings\Brisen\My Documents\Visual C++\Sports Management\PlayerRoster.mdb", TRUE, FALSE);

catch (CDaoException *e) {
CString error = e->m_pErrorInfo->m_strDescription;
MessageBox( error, "ERROR", MB_OK );

Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!