Click here to Skip to main content
15,925,868 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: On Edit box Pin
Chandrasekharan P20-Nov-07 19:02
Chandrasekharan P20-Nov-07 19:02 
GeneralRe: On Edit box Pin
David Crow21-Nov-07 3:04
David Crow21-Nov-07 3:04 
QuestionRe: On Edit box Pin
David Crow20-Nov-07 2:45
David Crow20-Nov-07 2:45 
AnswerRe: On Edit box Pin
Chandrasekharan P20-Nov-07 18:11
Chandrasekharan P20-Nov-07 18:11 
GeneralRe: On Edit box Pin
David Crow21-Nov-07 3:06
David Crow21-Nov-07 3:06 
QuestionHow to insert an icon in dialogue box Pin
Shaiju Ayyappan19-Nov-07 22:52
Shaiju Ayyappan19-Nov-07 22:52 
AnswerRe: How to insert an icon in dialogue box Pin
Haroon Sarwar19-Nov-07 22:59
Haroon Sarwar19-Nov-07 22:59 
AnswerRe: How to insert an icon in dialogue box Pin
Hamid_RT20-Nov-07 0:40
Hamid_RT20-Nov-07 0:40 
QuestionHow to insert a Control Panel Icon in Edit box Pin
Shaiju Ayyappan19-Nov-07 22:44
Shaiju Ayyappan19-Nov-07 22:44 
QuestionRe: How to insert a Control Panel Icon in Edit box Pin
David Crow20-Nov-07 2:50
David Crow20-Nov-07 2:50 
QuestionHow to Access PropertSheet in MainFrame class Pin
Atul2319-Nov-07 22:39
Atul2319-Nov-07 22:39 
AnswerRe: How to Access PropertSheet in MainFrame class Pin
Roger Broomfield19-Nov-07 23:02
Roger Broomfield19-Nov-07 23:02 
AnswerRe: How to Access PropertSheet in MainFrame class Pin
David Crow20-Nov-07 2:53
David Crow20-Nov-07 2:53 
Questionhow to detect process termination Pin
harsha u19-Nov-07 22:09
harsha u19-Nov-07 22:09 
AnswerRe: how to detect process termination Pin
ThatsAlok20-Nov-07 19:57
ThatsAlok20-Nov-07 19:57 
GeneralRe: how to detect process termination Pin
harsha u20-Nov-07 21:55
harsha u20-Nov-07 21:55 
QuestionLoading *.mht files from a stream using CHTMLView Pin
sdancer7519-Nov-07 22:05
sdancer7519-Nov-07 22:05 
QuestionHow to avoid warning LNK4224: /COMMENT is no longer supported Pin
mohindar_kks19-Nov-07 22:02
mohindar_kks19-Nov-07 22:02 
AnswerRe: How to avoid warning LNK4224: /COMMENT is no longer supported Pin
CPallini19-Nov-07 22:10
mveCPallini19-Nov-07 22:10 
AnswerRe: How to avoid warning LNK4224: /COMMENT is no longer supported Pin
Nelek19-Nov-07 22:24
protectorNelek19-Nov-07 22:24 
GeneralRe: How to avoid warning LNK4224: /COMMENT is no longer supported Pin
Cedric Moonen19-Nov-07 23:13
Cedric Moonen19-Nov-07 23:13 
GeneralRe: How to avoid warning LNK4224: /COMMENT is no longer supported Pin
Nelek19-Nov-07 23:49
protectorNelek19-Nov-07 23:49 
GeneralRe: How to avoid warning LNK4224: /COMMENT is no longer supported Pin
Cedric Moonen20-Nov-07 1:11
Cedric Moonen20-Nov-07 1:11 
I think it is bad because you can miss important warnings (things that you didn't thought about). You should get rid of the warnings instead of silenting them. I only disable them on some rare occasions.

C4181: why do you put the const keyword then ? If it will be ignored ? It let you think that it is used but it isn't so it can lead to confusion. Why don't you just remove it ? This will lead to the same result without warning.

C4018: why do you mix signed and unsigned ? That probably results to a bad design. They don't have the same range so if you start with a signed number, stick to it. On some rare occasion you will need to mix them, but then use an explicit cast.

C4244:

Nelek wrote:
SOLUTION: casting to the correct typ, but dont needed, but in this case I wanna lose the decimals by truncating and the constants must be float/double for other places to be used. And I have about 90 times this warning


Cast the complete block: (int)(4*GWIDTH)



Nelek wrote:
warning C4308: Negative Ganzzahlkonstante in vorzeichenlosen Typ konvertiert
//Conversion of negative integer constant in unsigned type
REASON: file->Seek (-3 * sizeof (BYTE), CFile::current);


That's typically one of the warning you shouldn't neglect, because your code is wrong. The warning tells you that it converts the -3 to an unsigned, so the result won't be what you expect. It does that because sizeof returns an unsigned type and so, when doing the multiplication your compiler will convert the -3 to unsigned type so that it can multiply both operands.


Cédric Moonen
Software developer

Charting control [v1.2]

GeneralRe: How to avoid warning LNK4224: /COMMENT is no longer supported Pin
Nelek20-Nov-07 2:24
protectorNelek20-Nov-07 2:24 
GeneralRe: How to avoid warning LNK4224: /COMMENT is no longer supported Pin
DoomedOne20-Nov-07 7:21
DoomedOne20-Nov-07 7: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.