Click here to Skip to main content
16,004,977 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
QuestionHow to enumerate all thread handles? Pin
Stephen Kellett4-Jan-02 6:58
Stephen Kellett4-Jan-02 6:58 
AnswerRe: How to enumerate all thread handles? Pin
Jon Newman4-Jan-02 8:19
Jon Newman4-Jan-02 8:19 
AnswerRe: How to enumerate all thread handles? Pin
Carlos Antollini4-Jan-02 8:44
Carlos Antollini4-Jan-02 8:44 
QuestionHow to get a thread handle from a thread id? Pin
Stephen Kellett4-Jan-02 6:55
Stephen Kellett4-Jan-02 6:55 
AnswerRe: How to get a thread handle from a thread id? Pin
4-Jan-02 7:17
suss4-Jan-02 7:17 
GeneralSnap controls onto Dialog Borders Pin
4-Jan-02 5:14
suss4-Jan-02 5:14 
GeneralRe: Snap controls onto Dialog Borders Pin
Michael Dunn4-Jan-02 7:54
sitebuilderMichael Dunn4-Jan-02 7:54 
General#import database and c2059 error : 'constant' Pin
AdamF4-Jan-02 5:13
AdamF4-Jan-02 5:13 
Hey,

First off if this is a really silly question then please excuse me but this is my first attempt at writing an application in c++.

I am trying to write a c++ program that can access a SQL Server database through ODBC/ADO(I don't care how just want it to work). I get c2059 error : 'constant'on the following line:

hr = m_pConnection->Open(_bstr_t(L"driver={sql server};SERVER=(local);Database=loggy;"),_bstr_t(L"sa"),_bstr_t(L"choices"),adModeUnknown);

Every command run after this complains about not being a member of _connection. I am using #import to import the msado15.dll whcih seems to be the best way(after many surfing hours). I would apreciate it if any one could help me. I think I have just put some code in the wrong place or something.

Thank you in advance

Regards

Adam


-------
Like you will ever visit my sites...
www.ufowatch.com - Seen a UFO then report it here or view over 500 different reports.

www.clubpages.co.uk - Taking the Bournemouth club scene through the millenium
GeneralVisual SourceSafe Passwords Pin
Chris Meech4-Jan-02 3:54
Chris Meech4-Jan-02 3:54 
GeneralRe: Visual SourceSafe Passwords Pin
Chris Meech4-Jan-02 9:11
Chris Meech4-Jan-02 9:11 
GeneralDOC/VIEW... Pin
Maverick4-Jan-02 3:27
Maverick4-Jan-02 3:27 
GeneralRe: DOC/VIEW... Pin
Sonu Kapoor4-Jan-02 3:37
Sonu Kapoor4-Jan-02 3:37 
GeneralRe: DOC/VIEW... Pin
4-Jan-02 3:46
suss4-Jan-02 3:46 
GeneralRe: DOC/VIEW... Pin
Sonu Kapoor4-Jan-02 4:15
Sonu Kapoor4-Jan-02 4:15 
GeneralRe: DOC/VIEW... Pin
Fazlul Kabir4-Jan-02 4:22
Fazlul Kabir4-Jan-02 4:22 
GeneralRe: DOC/VIEW... Pin
Sonu Kapoor4-Jan-02 4:25
Sonu Kapoor4-Jan-02 4:25 
GeneralRe: DOC/VIEW... Pin
Fazlul Kabir4-Jan-02 4:01
Fazlul Kabir4-Jan-02 4:01 
GeneralCapturing the numpad presses Pin
Mark Donkers4-Jan-02 3:20
Mark Donkers4-Jan-02 3:20 
GeneralRe: Capturing the numpad presses Pin
4-Jan-02 3:40
suss4-Jan-02 3:40 
GeneralRe: Capturing the numpad presses Pin
Mark Donkers4-Jan-02 3:52
Mark Donkers4-Jan-02 3:52 
GeneralRe: Capturing the numpad presses Pin
AJ1234-Jan-02 13:08
AJ1234-Jan-02 13:08 
GeneralRe: Capturing the numpad presses Pin
Rickard Andersson205-Jan-02 2:39
Rickard Andersson205-Jan-02 2:39 
GeneralRe: Capturing the numpad presses Pin
Mark Donkers7-Jan-02 3:24
Mark Donkers7-Jan-02 3:24 
GeneralNeed help on ShellExecute Print verb Pin
James P4-Jan-02 2:33
James P4-Jan-02 2:33 
GeneralRe: Need help on ShellExecute Print verb Pin
ColinDavies4-Jan-02 20:29
ColinDavies4-Jan-02 20:29 

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.