Click here to Skip to main content
15,914,444 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
QuestionactiveX wrapper files - how to generate? Pin
charlieg29-Aug-07 13:50
charlieg29-Aug-07 13:50 
AnswerRe: activeX wrapper files - how to generate? Pin
Mark Salsbery29-Aug-07 14:08
Mark Salsbery29-Aug-07 14:08 
QuestionCControlBar derived class example? Pin
Jerry Evans29-Aug-07 8:55
Jerry Evans29-Aug-07 8:55 
AnswerRe: CControlBar derived class example? Pin
bob1697229-Aug-07 12:10
bob1697229-Aug-07 12:10 
QuestionUsing CFile or CStdioFile with CEditView - how to copy the entire text Pin
Vaclav_29-Aug-07 8:21
Vaclav_29-Aug-07 8:21 
AnswerRe: Using CFile or CStdioFile with CEditView - how to copy the entire text Pin
Russell'29-Aug-07 9:09
Russell'29-Aug-07 9:09 
GeneralRe: Using CFile or CStdioFile with CEditView - how to copy the entire text Pin
Vaclav_29-Aug-07 10:28
Vaclav_29-Aug-07 10:28 
AnswerRe: Using CFile or CStdioFile with CEditView - how to copy the entire text Pin
Dennis Gourjii29-Aug-07 9:42
Dennis Gourjii29-Aug-07 9:42 
Error checking is skipped, but the code should be usable:

<br />
CFile file;<br />
file.Open("file.txt",CFile::modeRead);<br />
int len = file.GetLength();<br />
TCHAR pData = new TCHAR[len+1]; // +1 for terminating '\0'<br />
int read = file.Read(pData,(len+1)*sizeof(TCHAR));<br />
file[read] = '\0';<br />
// Could use CString in the following line, but what's the point?<br />
view_object.SetWindowText(pData);<br />
delete [] pData;<br />

GeneralRe: Using CFile or CStdioFile with CEditView - how to copy the entire text Pin
Vaclav_29-Aug-07 10:26
Vaclav_29-Aug-07 10:26 
QuestionRe: Using CFile or CStdioFile with CEditView - how to copy the entire text Pin
Mark Salsbery29-Aug-07 9:45
Mark Salsbery29-Aug-07 9:45 
AnswerRe: Using CFile or CStdioFile with CEditView - how to copy the entire text Pin
Vaclav_29-Aug-07 10:20
Vaclav_29-Aug-07 10:20 
GeneralRe: Using CFile or CStdioFile with CEditView - how to copy the entire text Pin
Mark Salsbery29-Aug-07 12:11
Mark Salsbery29-Aug-07 12:11 
QuestionData Sychronization Pin
Anthony988729-Aug-07 7:53
Anthony988729-Aug-07 7:53 
QuestionCallback functions???? Pin
pblais29-Aug-07 5:35
pblais29-Aug-07 5:35 
AnswerRe: Callback functions???? Pin
Russell'29-Aug-07 5:42
Russell'29-Aug-07 5:42 
GeneralRe: Callback functions???? Pin
pblais29-Aug-07 12:16
pblais29-Aug-07 12:16 
QuestionAccess violation when using STL map in DLL (VS7) Pin
Danny77uk29-Aug-07 5:10
Danny77uk29-Aug-07 5:10 
AnswerRe: Access violation when using STL map in DLL (VS7) Pin
led mike29-Aug-07 7:18
led mike29-Aug-07 7:18 
AnswerRe: Access violation when using STL map in DLL (VS7) Pin
Cedric Moonen29-Aug-07 7:20
Cedric Moonen29-Aug-07 7:20 
GeneralRe: Access violation when using STL map in DLL (VS7) Pin
Stephen Hewitt29-Aug-07 16:25
Stephen Hewitt29-Aug-07 16:25 
AnswerRe: Access violation when using STL map in DLL (VS7) Pin
George L. Jackson29-Aug-07 14:26
George L. Jackson29-Aug-07 14:26 
QuestionTCP/IP Sockets or Something New Pin
Andy20229-Aug-07 5:06
Andy20229-Aug-07 5:06 
AnswerRe: TCP/IP Sockets or Something New Pin
led mike29-Aug-07 7:13
led mike29-Aug-07 7:13 
AnswerRe: TCP/IP Sockets or Something New Pin
Mark Salsbery29-Aug-07 7:24
Mark Salsbery29-Aug-07 7:24 
QuestionGDI+ DrawImage Pin
TheShihan29-Aug-07 4:27
TheShihan29-Aug-07 4:27 

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.