Subj : Re: W8098 Multi-character character constant To : borland.public.cpp.borlandcpp From : "Jannie" Date : Mon Nov 24 2003 09:50 pm Thank you Bob Bob Gonder wrote: >Jannie wrote: > >>[C++ Warning] Unit1.cpp(17): W8098 Multi-character character constant >> >>Can anyone explain to me what this warning is about? > >You used single quotes around a string instead of double: >'Wrong' >"Right" > >When you use single qoutes, it is treated as a value (a number). >You can do something like the following: > >char h[] = "Hello World"; a string > >if *(DWORD*)h == 'Hell' ) a double word unsigned integer >You can use 1, 2 or 4 chars in a 'value' expression. > > .