Click here to Skip to main content
15,913,115 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: VC++ GUI App - Using Registry access functions Pin
David Crow28-Aug-06 4:06
David Crow28-Aug-06 4:06 
QuestionMaximize Application Pin
BlitzPackage27-Aug-06 15:34
BlitzPackage27-Aug-06 15:34 
AnswerRe: Maximize Application [modified] Pin
prasad_som27-Aug-06 20:10
prasad_som27-Aug-06 20:10 
GeneralRe: Maximize Application Pin
BlitzPackage28-Aug-06 2:38
BlitzPackage28-Aug-06 2:38 
Questionview the picture in other path by picture viewer Pin
sdhtyjnniutnbjnhbghb27-Aug-06 15:23
sdhtyjnniutnbjnhbghb27-Aug-06 15:23 
AnswerRe: view the picture in other path by picture viewer Pin
_AnsHUMAN_ 27-Aug-06 17:58
_AnsHUMAN_ 27-Aug-06 17:58 
GeneralRe: view the picture in other path by picture viewer Pin
sdhtyjnniutnbjnhbghb27-Aug-06 19:35
sdhtyjnniutnbjnhbghb27-Aug-06 19:35 
GeneralRe: view the picture in other path by picture viewer Pin
Hamid_RT27-Aug-06 21:14
Hamid_RT27-Aug-06 21:14 
GeneralRe: view the picture in other path by picture viewer Pin
sdhtyjnniutnbjnhbghb27-Aug-06 21:40
sdhtyjnniutnbjnhbghb27-Aug-06 21:40 
QuestionRe: view the picture in other path by picture viewer Pin
David Crow28-Aug-06 4:07
David Crow28-Aug-06 4:07 
AnswerRe: view the picture in other path by picture viewer Pin
sdhtyjnniutnbjnhbghb28-Aug-06 15:38
sdhtyjnniutnbjnhbghb28-Aug-06 15:38 
GeneralRe: view the picture in other path by picture viewer Pin
David Crow29-Aug-06 2:45
David Crow29-Aug-06 2:45 
QuestionNeed to end a string with null instead of \r\n Pin
samkook27-Aug-06 11:26
samkook27-Aug-06 11:26 
AnswerRe: Need to end a string with null instead of \r\n [modified] Pin
Waldermort27-Aug-06 11:41
Waldermort27-Aug-06 11:41 
GeneralRe: Need to end a string with null instead of \r\n [modified] Pin
samkook27-Aug-06 11:52
samkook27-Aug-06 11:52 
GeneralRe: Need to end a string with null instead of \r\n Pin
Waldermort27-Aug-06 12:00
Waldermort27-Aug-06 12:00 
GeneralRe: Need to end a string with null instead of \r\n Pin
samkook27-Aug-06 12:19
samkook27-Aug-06 12:19 
GeneralRe: Need to end a string with null instead of \r\n Pin
fefe.wyx27-Aug-06 14:42
fefe.wyx27-Aug-06 14:42 
GeneralRe: Need to end a string with null instead of \r\n Pin
David Crow28-Aug-06 4:11
David Crow28-Aug-06 4:11 
GeneralRe: Need to end a string with null instead of \r\n Pin
David Crow28-Aug-06 4:14
David Crow28-Aug-06 4:14 
AnswerRe: Need to end a string with null instead of \r\n Pin
kakan27-Aug-06 22:51
professionalkakan27-Aug-06 22:51 
GeneralRe: Need to end a string with null instead of \r\n Pin
samkook28-Aug-06 7:02
samkook28-Aug-06 7:02 
GeneralRe: Need to end a string with null instead of \r\n Pin
kakan28-Aug-06 19:31
professionalkakan28-Aug-06 19:31 
Hello.

I just debugged the code I gave you and it works as it should.
It removes any CR LF combinations from the end of the string.

The result is stored in str (assuming you do not delete the string before writing it to the file!).

My code will replace all terminating CR and LF with nulls in the buffer, that's right. But when you later uses the resulting buffer, it's the first null char that counts. Simply because a null char is seen as a string terminator.

If you want the length of the resulting string, just use strlen() (or it's variants).

PS.
English isn't my native lingo either.


Alcohol. The cause of, and the solution to, all of life's problems - Homer Simpson

QuestionScreen Sizes Pin
BlitzPackage27-Aug-06 9:58
BlitzPackage27-Aug-06 9:58 
AnswerRe: Screen Sizes Pin
Waldermort27-Aug-06 10:58
Waldermort27-Aug-06 10:58 

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.