Click here to Skip to main content
16,005,138 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Need help with encryption/decryption program Pin
cmk19-Aug-04 15:48
cmk19-Aug-04 15:48 
GeneralRe: Need help with encryption/decryption program Pin
JimmyRopes20-Aug-04 22:23
professionalJimmyRopes20-Aug-04 22:23 
GeneralMake CString to char* Pin
GGConsulting19-Aug-04 6:07
GGConsulting19-Aug-04 6:07 
GeneralRe: Make CString to char* Pin
toxcct19-Aug-04 6:15
toxcct19-Aug-04 6:15 
GeneralRe: Make CString to char* Pin
GGConsulting19-Aug-04 7:57
GGConsulting19-Aug-04 7:57 
GeneralRe: Make CString to char* Pin
GGConsulting19-Aug-04 8:00
GGConsulting19-Aug-04 8:00 
GeneralRe: Make CString to char* Pin
toxcct21-Aug-04 7:14
toxcct21-Aug-04 7:14 
GeneralRe: Make CString to char* Pin
Chris Meech19-Aug-04 6:43
Chris Meech19-Aug-04 6:43 
You are taking the address of an instance of a CString and casting it to a char*. That will not work as you have discovered. If you use 'toxcct' response you should find that may work fine. What that response does is use CString's ability to convert itself to a char*. However the pointer you are given is a const pointer and you are then casting away the const'ness. As long as you do not try to change the buffer contents that the pointer points to, you will be fine. But if you need non-const access, you will need to code this differently. Probably through some kind of Set method.

Chris Meech

I am Canadian. [heard in a local bar]

I think people should be required to have an operator's permit to use the internet. John Simmons

I have a feeling that if the millions of man hours wasted every year by geeks trying to get various video and sound cards working under Linux were put into some useful endeavor we'd have solved world hunger, we'd have peace and aids would be no more. [JOS poster]
GeneralRe: Make CString to char* Pin
BlackDice19-Aug-04 10:13
BlackDice19-Aug-04 10:13 
GeneralRe: Make CString to char* Pin
Jeff Bogan19-Aug-04 15:20
Jeff Bogan19-Aug-04 15:20 
GeneralfShared Memory Pin
Krishnan V19-Aug-04 5:37
Krishnan V19-Aug-04 5:37 
GeneralUninstall Blues Pin
Monty219-Aug-04 3:57
Monty219-Aug-04 3:57 
GeneralRe: Uninstall Blues Pin
David Crow19-Aug-04 4:58
David Crow19-Aug-04 4:58 
GeneralRe: Uninstall Blues Pin
toxcct19-Aug-04 5:01
toxcct19-Aug-04 5:01 
GeneralRe: Uninstall Blues Pin
David Crow19-Aug-04 5:07
David Crow19-Aug-04 5:07 
QuestionHow to Initialize an array of user selected size Pin
Deepak Samuel19-Aug-04 3:45
Deepak Samuel19-Aug-04 3:45 
AnswerRe: How to Initialize an array of user selected size Pin
RChin19-Aug-04 3:59
RChin19-Aug-04 3:59 
Generalnoisy AfxMessageBox Pin
V.19-Aug-04 3:27
professionalV.19-Aug-04 3:27 
GeneralRe: noisy AfxMessageBox Pin
RChin19-Aug-04 3:52
RChin19-Aug-04 3:52 
GeneralProgram Starts Minized Pin
sweep12319-Aug-04 3:25
sweep12319-Aug-04 3:25 
GeneralRe: Program Starts Minized Pin
RichardS19-Aug-04 3:51
RichardS19-Aug-04 3:51 
GeneralRe: Program Starts Minized Pin
sweep12319-Aug-04 5:45
sweep12319-Aug-04 5:45 
GeneralRe: Program Starts Minized Pin
gamitech19-Aug-04 10:57
gamitech19-Aug-04 10:57 
GeneralRe: Program Starts Minized Pin
Ryan Binns19-Aug-04 18:25
Ryan Binns19-Aug-04 18:25 
GeneralSuspending external application Pin
WzR19-Aug-04 3:08
WzR19-Aug-04 3:08 

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.