Click here to Skip to main content
15,925,505 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: Those little Indians Pin
Maxwell Chen16-Apr-06 0:04
Maxwell Chen16-Apr-06 0:04 
QuestionVC++ 6 problem Pin
shormi15-Apr-06 18:32
shormi15-Apr-06 18:32 
AnswerRe: VC++ 6 problem Pin
Ryan Binns15-Apr-06 22:01
Ryan Binns15-Apr-06 22:01 
GeneralRe: VC++ 6 problem Pin
shormi15-Apr-06 22:04
shormi15-Apr-06 22:04 
QuestionGet class info from file. ERROR? Pin
Virlene Cheng15-Apr-06 18:25
Virlene Cheng15-Apr-06 18:25 
AnswerRe: Get class info from file. ERROR? Pin
Stephen Hewitt15-Apr-06 18:35
Stephen Hewitt15-Apr-06 18:35 
AnswerRe: Get class info from file. ERROR? Pin
Ryan Binns15-Apr-06 22:05
Ryan Binns15-Apr-06 22:05 
QuestionDLL Thread Help Pin
borono15-Apr-06 18:12
borono15-Apr-06 18:12 
hey, I am trying to send a variable from vb to vc6 dll, which will specify which adapter to open. The count for this machine, for instance, is 3. When the user selects a device from the list in VB, they click start and the VB app sends the corresponding number --lets say 2. Then the DLL receives the long variable and converts to u_int and shaves off one, so the value becomes 1. This value is then ran through a for loop, stopping on the device we want. This stores the name of the device in a variable which is used to open the device. All of this is currently done in a thread.

When cycling through the devices in the for loop, it always skips the first device. So, if the user wants to use device 1 of 3, the dll wont use 0, instead it fails, because 0 doesn't exist to it.

If I do the for loop in a function outside the thread, it sees all three, but I can't pass the thread the devs name, because it needs to be initilised in thread. At least that is how it seems, considering it caused a crash at run-time. I simply tried to define the variable the device opening portion needs in the separate function, I didn't actually pass it from the separate function to the thread function. I am not sure how or even if I can pass an argument to the thread function.

My question is, why wont the dll see three devs in the thread, though it sees them in the separate function? And, what do I need to do to fix it? If you need more info, let me know. Thanks in advance, have a nice day.
AnswerRe: DLL Thread Help Pin
Waldermort15-Apr-06 19:51
Waldermort15-Apr-06 19:51 
GeneralRe: DLL Thread Help Pin
borono16-Apr-06 7:28
borono16-Apr-06 7:28 
QuestionPorting VC6 to VC8 Pin
PJ Arends15-Apr-06 11:30
professionalPJ Arends15-Apr-06 11:30 
AnswerRe: Porting VC6 to VC8 Pin
PJ Arends15-Apr-06 11:56
professionalPJ Arends15-Apr-06 11:56 
GeneralRe: Porting VC6 to VC8 Pin
Jörgen Sigvardsson15-Apr-06 13:12
Jörgen Sigvardsson15-Apr-06 13:12 
GeneralRe: Porting VC6 to VC8 Pin
PJ Arends15-Apr-06 13:34
professionalPJ Arends15-Apr-06 13:34 
GeneralRe: Porting VC6 to VC8 Pin
Ryan Binns15-Apr-06 22:10
Ryan Binns15-Apr-06 22:10 
Questionreading from database Pin
aguest15-Apr-06 11:23
aguest15-Apr-06 11:23 
AnswerRe: reading from database Pin
Maxwell Chen15-Apr-06 17:39
Maxwell Chen15-Apr-06 17:39 
QuestionNative Apps Pin
Julian Goldsmith15-Apr-06 10:52
Julian Goldsmith15-Apr-06 10:52 
AnswerRe: Native Apps Pin
Maxwell Chen15-Apr-06 17:36
Maxwell Chen15-Apr-06 17:36 
Questionhow would i get the windows directory in kernel mode? Pin
Jimmy638915-Apr-06 10:35
Jimmy638915-Apr-06 10:35 
AnswerRe: how would i get the windows directory in kernel mode? Pin
Julian Goldsmith15-Apr-06 10:54
Julian Goldsmith15-Apr-06 10:54 
QuestionHow to get internet connection speed ??? Pin
IvanBeograd15-Apr-06 10:30
IvanBeograd15-Apr-06 10:30 
AnswerRe: How to get internet connection speed ??? Pin
IvanBeograd16-Apr-06 10:14
IvanBeograd16-Apr-06 10:14 
Questioninline declaration? Pin
9ine15-Apr-06 7:37
9ine15-Apr-06 7:37 
AnswerRe: inline declaration? Pin
Maxwell Chen15-Apr-06 8:03
Maxwell Chen15-Apr-06 8:03 

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.