Click here to Skip to main content
15,892,005 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: error C3861? Pin
RichardS16-Mar-06 23:51
RichardS16-Mar-06 23:51 
AnswerRe: error C3861? Pin
ThatsAlok17-Mar-06 0:51
ThatsAlok17-Mar-06 0:51 
Questionconversion from 'double' to 'unsigned int', Pin
ariesaloksingh16-Mar-06 18:25
ariesaloksingh16-Mar-06 18:25 
AnswerRe: conversion from 'double' to 'unsigned int', Pin
Hamid_RT16-Mar-06 18:34
Hamid_RT16-Mar-06 18:34 
AnswerRe: conversion from 'double' to 'unsigned int', Pin
Stephen Hewitt16-Mar-06 19:46
Stephen Hewitt16-Mar-06 19:46 
AnswerRe: conversion from 'double' to 'unsigned int', Pin
Johann Gerell16-Mar-06 22:02
Johann Gerell16-Mar-06 22:02 
AnswerRe: conversion from 'double' to 'unsigned int', Pin
rwilmink16-Mar-06 22:39
rwilmink16-Mar-06 22:39 
AnswerYou can not!!! Pin
normanS16-Mar-06 23:05
normanS16-Mar-06 23:05 
The answer, quite simply, is that you can not in general convert from double (or float) to unsigned int with no data loss!

Because double is a floating point format, it might contain a fractional part, which will be discarded in any conversion.

And a double might be very large or very small (because it allows powers of 10.)

If the double represents an integer in the range supported by an unsigned int, then no conversion is necessary - it can be stored.

Lastly, if the double represents something like degrees, with resolution of 0.01 degree and range of 0 to 359.99 degree, you could scale the value - multiply the double by 100.0, add 0.1, then store it in the unsigned int with no data loss.

AnswerRe: conversion from 'double' to 'unsigned int', Pin
Ștefan-Mihai MOGA17-Mar-06 2:50
professionalȘtefan-Mihai MOGA17-Mar-06 2:50 
QuestionHelp - Print out is in the format of horizontal flip Pin
kezhu16-Mar-06 18:05
kezhu16-Mar-06 18:05 
Questionhow to put image in right side of item in listcontrol Pin
lorey16-Mar-06 18:00
lorey16-Mar-06 18:00 
QuestionLoading application along with the data from folder. Pin
Giirsh116-Mar-06 17:28
Giirsh116-Mar-06 17:28 
AnswerRe: Loading application along with the data from folder. Pin
Nibu babu thomas16-Mar-06 17:31
Nibu babu thomas16-Mar-06 17:31 
AnswerRe: Loading application along with the data from folder. Pin
Xing Chen16-Mar-06 18:03
Xing Chen16-Mar-06 18:03 
QuestionRe: Loading application along with the data from folder. Pin
Giirsh116-Mar-06 18:35
Giirsh116-Mar-06 18:35 
AnswerRe: Loading application along with the data from folder. Pin
Cool Ju16-Mar-06 19:07
Cool Ju16-Mar-06 19:07 
AnswerRe: Loading application along with the data from folder. Pin
Xing Chen16-Mar-06 19:16
Xing Chen16-Mar-06 19:16 
Questiongraphic.h in Visual c++ Pin
Aqueel16-Mar-06 16:57
Aqueel16-Mar-06 16:57 
AnswerRe: graphic.h in Visual c++ Pin
Naveen16-Mar-06 17:02
Naveen16-Mar-06 17:02 
AnswerRe: graphic.h in Visual c++ Pin
Eytukan16-Mar-06 20:03
Eytukan16-Mar-06 20:03 
AnswerRe: graphic.h in Visual c++ Pin
ThatsAlok17-Mar-06 0:53
ThatsAlok17-Mar-06 0:53 
GeneralRe: graphic.h in Visual c++ Pin
Aqueel17-Mar-06 18:36
Aqueel17-Mar-06 18:36 
GeneralRe: graphic.h in Visual c++ Pin
ThatsAlok17-Mar-06 21:14
ThatsAlok17-Mar-06 21:14 
QuestionHelp with set SQL cursor to SQL_SCROLLABLE Pin
nhuythanh16-Mar-06 16:03
nhuythanh16-Mar-06 16:03 
AnswerRe: Help with set SQL cursor to SQL_SCROLLABLE Pin
Gerald Schwab16-Mar-06 17:28
Gerald Schwab16-Mar-06 17:28 

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.