Click here to Skip to main content
15,890,438 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: Message box display twice Pin
theCPkid22-Sep-09 21:40
theCPkid22-Sep-09 21:40 
Questionautomation files and excel Pin
prithaa22-Sep-09 20:40
prithaa22-Sep-09 20:40 
QuestionHelp with regex in VS2008 Pin
theCPkid22-Sep-09 20:22
theCPkid22-Sep-09 20:22 
AnswerRe: Help with regex in VS2008 Pin
theCPkid22-Sep-09 21:37
theCPkid22-Sep-09 21:37 
QuestionSave as Excel file Pin
Davitor22-Sep-09 19:58
Davitor22-Sep-09 19:58 
AnswerRe: Save as Excel file Pin
Davitor22-Sep-09 21:29
Davitor22-Sep-09 21:29 
GeneralRe: Save as Excel file Pin
Chandrasekharan P23-Sep-09 4:06
Chandrasekharan P23-Sep-09 4:06 
GeneralRe: Save as Excel file Pin
Davitor23-Sep-09 18:13
Davitor23-Sep-09 18:13 
QuestionODBC error: Expression too complex Expression too complex [modified] Pin
narendra91122-Sep-09 18:53
narendra91122-Sep-09 18:53 
GeneralRe: ODBC error: Expression too complex Expression too complex [modified] Pin
narendra91123-Sep-09 5:44
narendra91123-Sep-09 5:44 
QuestionODBC error: Expression too complex Pin
narendra91122-Sep-09 18:52
narendra91122-Sep-09 18:52 
GeneralRe: ODBC error: Expression too complex [modified] Pin
narendra91123-Sep-09 5:44
narendra91123-Sep-09 5:44 
QuestionCalling The Thread function Pin
VVVimal22-Sep-09 18:50
VVVimal22-Sep-09 18:50 
AnswerRe: Calling The Thread function Pin
Naveen22-Sep-09 19:26
Naveen22-Sep-09 19:26 
AnswerRe: Calling The Thread function Pin
chandu00422-Sep-09 20:44
chandu00422-Sep-09 20:44 
QuestionThread Pin
VVVimal22-Sep-09 18:49
VVVimal22-Sep-09 18:49 
AnswerRe: Thread Pin
CPallini22-Sep-09 20:54
mveCPallini22-Sep-09 20:54 
QuestionQuestion about structure [modified] Pin
liang30622-Sep-09 16:59
liang30622-Sep-09 16:59 
AnswerRe: Question about structure Pin
Naveen22-Sep-09 18:39
Naveen22-Sep-09 18:39 
Question[Solved] What is the 32-bit form of the _InterlockedIncrement intrinsic? Pin
Skippums22-Sep-09 8:15
Skippums22-Sep-09 8:15 
AnswerRe: What is the 32-bit form of the _InterlockedIncrement intrinsic? Pin
cmk22-Sep-09 10:24
cmk22-Sep-09 10:24 
A failing on MS part i think.

http://msdn.microsoft.com/en-us/library/29dh1w7z(VS.80).aspx[^]

__in32 == int, int != long (as data types are concerned).
They should have made __int32 == long.

You have 2 choices:

__int32 atomicInc(__int32 *val) {
return (__int32)_InterlockedIncrement((long*)val);
}

or

__int32 atomicInc(long *val) {
return (__int32)_InterlockedIncrement(val);
}

...cmk

The idea that I can be presented with a problem, set out to logically solve it with the tools at hand, and wind up with a program that could not be legally used because someone else followed the same logical steps some years ago and filed for a patent on it is horrifying.
- John Carmack

GeneralRe: What is the 32-bit form of the _InterlockedIncrement intrinsic? Pin
Skippums22-Sep-09 10:53
Skippums22-Sep-09 10:53 
GeneralRe: What is the 32-bit form of the _InterlockedIncrement intrinsic? Pin
cmk22-Sep-09 10:59
cmk22-Sep-09 10:59 
GeneralRe: What is the 32-bit form of the _InterlockedIncrement intrinsic? Pin
Skippums22-Sep-09 11:14
Skippums22-Sep-09 11:14 
GeneralRe: What is the 32-bit form of the _InterlockedIncrement intrinsic? Pin
cmk22-Sep-09 11:55
cmk22-Sep-09 11:55 

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.