Click here to Skip to main content
15,912,977 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Some help of how i can send files remotely in network. Pin
KRowe31-Oct-04 21:03
KRowe31-Oct-04 21:03 
GeneralConnection to MS Access Database Pin
WinAPILearner31-Oct-04 8:08
WinAPILearner31-Oct-04 8:08 
GeneralRe: Connection to MS Access Database Pin
David Crow1-Nov-04 6:27
David Crow1-Nov-04 6:27 
GeneralRe: Connection to MS Access Database Pin
WinAPILearner1-Nov-04 21:34
WinAPILearner1-Nov-04 21:34 
GeneralRe: Connection to MS Access Database Pin
David Crow2-Nov-04 2:30
David Crow2-Nov-04 2:30 
GeneralRe: Connection to MS Access Database Pin
David Crow2-Nov-04 7:48
David Crow2-Nov-04 7:48 
GeneralRe: Connection to MS Access Database Pin
David Crow2-Nov-04 8:04
David Crow2-Nov-04 8:04 
GeneralRe: Connection to MS Access Database Pin
WinAPILearner2-Nov-04 10:09
WinAPILearner2-Nov-04 10:09 
Under the odbcsqlconnect.asp I copied this sample code, but it give me 9 Errors. Some others do not have samples. I get a lot of errors including any SQLxx.h files.

SQLHENV henv;
SQLHDBC hdbc;
SQLHSTMT hstmt;
SQLRETURN retcode;

/*Allocate environment handle */
retcode = SQLAllocHandle(SQL_HANDLE_ENV, SQL_NULL_HANDLE, &henv);

if (retcode == SQL_SUCCESS || retcode == SQL_SUCCESS_WITH_INFO) {
/* Set the ODBC version environment attribute */
retcode = SQLSetEnvAttr(henv, SQL_ATTR_ODBC_VERSION, (void*)SQL_OV_ODBC3, 0);

if (retcode == SQL_SUCCESS || retcode == SQL_SUCCESS_WITH_INFO) {
/* Allocate connection handle */
retcode = SQLAllocHandle(SQL_HANDLE_DBC, henv, &hdbc);

if (retcode == SQL_SUCCESS || retcode == SQL_SUCCESS_WITH_INFO) {
/* Set login timeout to 5 seconds. */
SQLSetConnectAttr(hdbc, (void*)SQL_LOGIN_TIMEOUT, 5, 0);

/* Connect to data source */
retcode = SQLConnect(hdbc, (SQLCHAR*) "TEST", SQL_NTS,
(SQLCHAR*) "tUser", SQL_NTS,
(SQLCHAR*) "tPass", SQL_NTS);

if (retcode == SQL_SUCCESS || retcode == SQL_SUCCESS_WITH_INFO){
/* Allocate statement handle */
retcode = SQLAllocHandle(SQL_HANDLE_STMT, hdbc, &hstmt);

if (retcode == SQL_SUCCESS || retcode == SQL_SUCCESS_WITH_INFO) {
/* Process data */
// ;
// ;
// ;
//
SQLFreeHandle(SQL_HANDLE_STMT, hstmt);
}
SQLDisconnect(hdbc);
}
SQLFreeHandle(SQL_HANDLE_DBC, hdbc);
}
}
SQLFreeHandle(SQL_HANDLE_ENV, henv);
}

GeneralRe: Connection to MS Access Database Pin
David Crow2-Nov-04 10:24
David Crow2-Nov-04 10:24 
GeneralRe: Connection to MS Access Database Pin
WinAPILearner2-Nov-04 20:12
WinAPILearner2-Nov-04 20:12 
GeneralRe: Connection to MS Access Database Pin
David Crow3-Nov-04 2:31
David Crow3-Nov-04 2:31 
GeneralRe: Connection to MS Access Database Pin
WinAPILearner3-Nov-04 7:42
WinAPILearner3-Nov-04 7:42 
GeneralRe: Connection to MS Access Database Pin
David Crow3-Nov-04 9:41
David Crow3-Nov-04 9:41 
GeneralConsole Threading Problem Pin
Joe_Sextus31-Oct-04 7:36
Joe_Sextus31-Oct-04 7:36 
GeneralRe: Console Threading Problem Pin
Ryan Binns31-Oct-04 17:57
Ryan Binns31-Oct-04 17:57 
GeneralRe: Console Threading Problem Pin
Joe_Sextus31-Oct-04 18:31
Joe_Sextus31-Oct-04 18:31 
GeneralRe: Operating System for Developers Pin
Christian Graus31-Oct-04 9:07
protectorChristian Graus31-Oct-04 9:07 
QuestionHow to hook system API under windows 9x? Pin
jedyking31-Oct-04 6:36
jedyking31-Oct-04 6:36 
AnswerRe: How to hook system API under windows 9x? Pin
User 665831-Oct-04 8:25
User 665831-Oct-04 8:25 
GeneralRe: How to hook system API under windows 9x? Pin
jedyking1-Nov-04 5:28
jedyking1-Nov-04 5:28 
AnswerRe: How to hook system API under windows 9x? Pin
ThatsAlok31-Oct-04 17:29
ThatsAlok31-Oct-04 17:29 
GeneralRe: How to hook system API under windows 9x? Pin
jedyking1-Nov-04 5:27
jedyking1-Nov-04 5:27 
GeneralTAPI givin link error Pin
asif m@hmood31-Oct-04 5:46
asif m@hmood31-Oct-04 5:46 
GeneralRe: TAPI givin link error Pin
Michael P Butler31-Oct-04 6:18
Michael P Butler31-Oct-04 6:18 
Questionhow to enable... Pin
Natural_Demon31-Oct-04 4:19
Natural_Demon31-Oct-04 4:19 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.