Click here to Skip to main content
15,922,574 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: What is wrong with my project setting? Pin
«_Superman_»3-Nov-09 11:10
professional«_Superman_»3-Nov-09 11:10 
General[Message Deleted] Pin
transoft3-Nov-09 11:25
transoft3-Nov-09 11:25 
GeneralRe: What is wrong with my project setting? Pin
«_Superman_»3-Nov-09 11:26
professional«_Superman_»3-Nov-09 11:26 
AnswerRe: What is wrong with my project setting? Pin
Richard MacCutchan3-Nov-09 11:33
mveRichard MacCutchan3-Nov-09 11:33 
AnswerRe: What is wrong with my project setting? Pin
dxlee3-Nov-09 14:37
dxlee3-Nov-09 14:37 
QuestionRe: What is wrong with my project setting? Pin
David Crow4-Nov-09 3:24
David Crow4-Nov-09 3:24 
AnswerRe: What is wrong with my project setting? Pin
transoft4-Nov-09 6:34
transoft4-Nov-09 6:34 
Questionnewbie api pointers question Pin
egerving3-Nov-09 10:37
egerving3-Nov-09 10:37 
The following function is as follows
LONG ITCSCAN_GetDefaultDevice(
LPTSTR lpDeviceNameBuffer,
DWORD * pBufferLength)

with explanation as follows

lpDeviceNameBuffer [out] Pointer to buffer that will store the returned device name

pBufferLength [in/out]Pointer to a variable that specifies the size, in bytes, of the buffer pointed to by the lpDeviceNameBuffer parameter. When the function returns, this variable contains the size of the data copied to lpDeviceNameBuffer

I under stand pointer points to address and I understand that dereference points to value at an address. But these Windows API functions have me confused, expecially with the out in/out stuff.

Can anyone make this clearer using the above function as example.

I would code
LONG defaultDevice;
LPTSTR deviceBuffer=NULL;
DWORD *bufferLength=NULL;

defaultDevice = ITCSCAN_GetDefaultDevice(deviceBuffer,bufferLength)

But that returns errors and when I've made changes to get the code to compile without errors I get access violation runtime errors.

Please Help!
QuestionRe: newbie api pointers question Pin
David Crow3-Nov-09 10:51
David Crow3-Nov-09 10:51 
AnswerRe: newbie api pointers question Pin
egerving3-Nov-09 11:26
egerving3-Nov-09 11:26 
GeneralRe: newbie api pointers question Pin
Richard MacCutchan3-Nov-09 11:41
mveRichard MacCutchan3-Nov-09 11:41 
GeneralRe: newbie api pointers question Pin
egerving3-Nov-09 12:01
egerving3-Nov-09 12:01 
AnswerRe: newbie api pointers question Pin
Randor 3-Nov-09 11:01
professional Randor 3-Nov-09 11:01 
AnswerRe: newbie api pointers question Pin
egerving3-Nov-09 11:26
egerving3-Nov-09 11:26 
GeneralRe: newbie api pointers question Pin
Randor 3-Nov-09 11:31
professional Randor 3-Nov-09 11:31 
GeneralRe: newbie api pointers question Pin
egerving3-Nov-09 11:45
egerving3-Nov-09 11:45 
GeneralRe: newbie api pointers question Pin
Randor 3-Nov-09 11:53
professional Randor 3-Nov-09 11:53 
GeneralRe: newbie api pointers question Pin
egerving3-Nov-09 12:10
egerving3-Nov-09 12:10 
GeneralRe: newbie api pointers question Pin
Randor 3-Nov-09 12:12
professional Randor 3-Nov-09 12:12 
QuestionAbout autorun of any exe file in Windows and autorun of file in Linux Pin
WindowsVsLinux3-Nov-09 7:46
WindowsVsLinux3-Nov-09 7:46 
Questionwifstream operator >> Pin
transoft3-Nov-09 5:35
transoft3-Nov-09 5:35 
AnswerRe: wifstream operator >> Pin
David Crow3-Nov-09 5:58
David Crow3-Nov-09 5:58 
GeneralRe: wifstream operator >> [modified] Pin
transoft3-Nov-09 7:49
transoft3-Nov-09 7:49 
QuestionRe: wifstream operator >> Pin
David Crow3-Nov-09 8:05
David Crow3-Nov-09 8:05 
AnswerRe: wifstream operator >> Pin
transoft3-Nov-09 8:18
transoft3-Nov-09 8:18 

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.