Click here to Skip to main content
15,895,142 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
QuestionIs this possible? Pin
leppie5-Aug-03 9:30
leppie5-Aug-03 9:30 
AnswerRe: Is this possible? Pin
Michael Dunn5-Aug-03 14:48
sitebuilderMichael Dunn5-Aug-03 14:48 
Generalquestion about : operator Pin
jholwick5-Aug-03 9:16
jholwick5-Aug-03 9:16 
GeneralRe: question about : operator Pin
markkuk5-Aug-03 9:25
markkuk5-Aug-03 9:25 
GeneralOT Pin
Michael Dunn5-Aug-03 14:50
sitebuilderMichael Dunn5-Aug-03 14:50 
GeneralRe: OT Pin
Nick Parker5-Aug-03 17:54
protectorNick Parker5-Aug-03 17:54 
GeneralRe: OT Pin
Michael Dunn6-Aug-03 6:57
sitebuilderMichael Dunn6-Aug-03 6:57 
GeneralCoTaskMemAlloc... Pin
halblonious5-Aug-03 9:14
halblonious5-Aug-03 9:14 
Does anyone know why there would be a problem using this on seemingly ONLY some XP systems? I guess it doesn't allocate the memory, and it returns NULL when I use it in:

LPVOID pData = CoTaskMemAlloc(BufferSize);

TRY
{
RegQueryValueEx(Sub3,"OBJECTS",NULL,&RegistrySize,(BYTE*)pData,&BufferSize);
}
CATCH(CException,e)
{
#ifdef _DEBUG
MessageBoxes(3);//this is an error/exit function
RegCloseKey(Sub3);
#endif
}
END_CATCH

In order to set the right size to BufferSize, I call it with NULL in place of the pData first. Is there a better way to do this, or a different function that works with XP consistently, or am I doing something wrong?

halblonious
GeneralOne of us is hallucinating. Pin
WREY5-Aug-03 8:50
WREY5-Aug-03 8:50 
GeneralRe: One of us is hallucinating. Pin
valikac5-Aug-03 9:39
valikac5-Aug-03 9:39 
GeneralRe: One of us is hallucinating. Pin
WREY5-Aug-03 10:04
WREY5-Aug-03 10:04 
GeneralRe: One of us is hallucinating. Pin
valikac5-Aug-03 10:22
valikac5-Aug-03 10:22 
GeneralProgress made. Pin
WREY5-Aug-03 10:48
WREY5-Aug-03 10:48 
GeneralRe: One of us is hallucinating. Pin
l a u r e n5-Aug-03 11:58
l a u r e n5-Aug-03 11:58 
GeneralRe: One of us is hallucinating. Pin
WREY5-Aug-03 12:51
WREY5-Aug-03 12:51 
GeneralRe: One of us is hallucinating. Pin
Atlantys5-Aug-03 16:17
Atlantys5-Aug-03 16:17 
GeneralRe: One of us is hallucinating. Pin
WREY5-Aug-03 18:29
WREY5-Aug-03 18:29 
GeneralRe: One of us is hallucinating. Pin
Toni785-Aug-03 22:18
Toni785-Aug-03 22:18 
GeneralRe: One of us is hallucinating. Pin
WREY6-Aug-03 6:26
WREY6-Aug-03 6:26 
GeneralRe: One of us is hallucinating. Pin
Atlantys6-Aug-03 5:57
Atlantys6-Aug-03 5:57 
Generalreading in a file and storing the words in a char[] Pin
johnstonsk5-Aug-03 8:44
johnstonsk5-Aug-03 8:44 
GeneralRe: reading in a file and storing the words in a char[] Pin
canniballl5-Aug-03 9:17
canniballl5-Aug-03 9:17 
GeneralRe: reading in a file and storing the words in a char[] Pin
johnstonsk5-Aug-03 9:34
johnstonsk5-Aug-03 9:34 
GeneralRe: Windows API related problem.... Pin
Bob Stanneveld5-Aug-03 8:14
Bob Stanneveld5-Aug-03 8:14 
GeneralRe: Windows API related problem.... Pin
Maximilien5-Aug-03 8:43
Maximilien5-Aug-03 8:43 

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.