Click here to Skip to main content
15,902,112 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Cut a bitmap under GDI+ Pin
Mark Salsbery12-Jul-07 5:08
Mark Salsbery12-Jul-07 5:08 
QuestionHelp aout paint none-client area Pin
kcynic11-Jul-07 6:22
kcynic11-Jul-07 6:22 
AnswerRe: Help aout paint none-client area Pin
DevMentor.org12-Jul-07 12:01
DevMentor.org12-Jul-07 12:01 
GeneralRe: Help aout paint none-client area Pin
kcynic13-Jul-07 1:00
kcynic13-Jul-07 1:00 
GeneralRe: Help aout paint none-client area Pin
DevMentor.org13-Jul-07 12:10
DevMentor.org13-Jul-07 12:10 
GeneralRe: Help aout paint none-client area Pin
kcynic13-Jul-07 12:26
kcynic13-Jul-07 12:26 
GeneralRe: Help aout paint none-client area Pin
DevMentor.org13-Jul-07 20:46
DevMentor.org13-Jul-07 20:46 
QuestionConvert Int to Byte Pin
simoncoul11-Jul-07 6:19
simoncoul11-Jul-07 6:19 
I'm trying to convert and short int into 2 bytes to be send through an ethernet comm. This is what I'm trying to do:

    char calcsendbuf[3];
short int data;
printf("Please Enter The Data:");
scanf("%d", &data);
calcsendbuf[0] = char(data % 256);
calcsendbuf[1] = char(floor(double(data/256)));
printf("byte 0: %u\n", calcsendbuf[0]);
printf("byte 1: %u\n", calcsendbuf[1]);


I input 32767 as the data and it should be printing 255 and 127, but I'm getting 4294967295 and 127. Any ideas of what is going wrong here, or maybe a different way of doing things?

Thanks
AnswerRe: Convert Int to Byte Pin
David Crow11-Jul-07 7:21
David Crow11-Jul-07 7:21 
AnswerRe: Convert Int to Byte Pin
Cyrilix11-Jul-07 7:21
Cyrilix11-Jul-07 7:21 
GeneralRe: Convert Int to Byte Pin
simoncoul11-Jul-07 7:52
simoncoul11-Jul-07 7:52 
GeneralRe: Convert Int to Byte Pin
Cyrilix11-Jul-07 8:13
Cyrilix11-Jul-07 8:13 
GeneralRe: Convert Int to Byte Pin
simoncoul11-Jul-07 8:25
simoncoul11-Jul-07 8:25 
QuestionParameter passsing between classes Pin
chaitannya_m11-Jul-07 6:03
chaitannya_m11-Jul-07 6:03 
AnswerRe: Parameter passsing between classes Pin
Electronic7511-Jul-07 6:10
Electronic7511-Jul-07 6:10 
GeneralRe: Parameter passsing between classes Pin
chaitannya_m11-Jul-07 6:54
chaitannya_m11-Jul-07 6:54 
GeneralRe: Parameter passsing between classes Pin
sheshidar11-Jul-07 18:07
sheshidar11-Jul-07 18:07 
AnswerRe: Parameter passsing between classes Pin
chaitannya_m11-Jul-07 7:29
chaitannya_m11-Jul-07 7:29 
QuestionRe: Parameter passsing between classes Pin
JudyL_MD11-Jul-07 7:40
JudyL_MD11-Jul-07 7:40 
AnswerRe: Parameter passsing between classes Pin
chaitannya_m11-Jul-07 9:04
chaitannya_m11-Jul-07 9:04 
GeneralRe: Parameter passsing between classes Pin
JudyL_MD12-Jul-07 3:41
JudyL_MD12-Jul-07 3:41 
Questionrun an EXE for all users of the computer Pin
rahul398511-Jul-07 5:29
rahul398511-Jul-07 5:29 
QuestionRe: run an EXE for all users of the computer Pin
David Crow11-Jul-07 6:00
David Crow11-Jul-07 6:00 
AnswerRe: run an EXE for all users of the computer Pin
Randor 11-Jul-07 6:22
professional Randor 11-Jul-07 6:22 
QuestionHow to get IDD of a PropertyPage dialog? [modified] Pin
Electronic7511-Jul-07 5:21
Electronic7511-Jul-07 5:21 

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.