Click here to Skip to main content
16,006,476 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralDeleting Executable Files In Windows... Pin
cyberm3k17-Jun-02 16:29
cyberm3k17-Jun-02 16:29 
GeneralRe: Deleting Executable Files In Windows... Pin
perlmunger19-Jun-02 10:27
perlmunger19-Jun-02 10:27 
GeneralCArray problem Pin
17-Jun-02 15:44
suss17-Jun-02 15:44 
GeneralRe: CArray problem Pin
Martin Marvinski17-Jun-02 16:36
Martin Marvinski17-Jun-02 16:36 
GeneralRe: CArray problem Pin
Renjith Ramachandran17-Jun-02 17:48
Renjith Ramachandran17-Jun-02 17:48 
GeneralRe: CArray problem Pin
17-Jun-02 23:07
suss17-Jun-02 23:07 
GeneralRe: CArray problem Pin
Christian Graus17-Jun-02 23:32
protectorChristian Graus17-Jun-02 23:32 
GeneralRe: CArray problem Pin
Sprudling18-Jun-02 2:13
Sprudling18-Jun-02 2:13 
Instead of returning a CArray (which is impossible no matter what you do since it's a template class; but that's another story) do this:

void CMyClass::MyFunction(CStringArray& a)
{
    CString str_component = "test";
    a.add(str_component);
}
#include "afxtempl.h" to use the class 'CStringArray'. To use 'MyFunction' do like this:

void CMyClass::AnotherFunction()
{
    CStringArray myArray;
    this->MyFunction(myArray);
}
After the call to 'MyFunction' the string is still added since the array is sent by reference. And there is no need for a copy constructor for the same reason.

Sprudling
GeneralSTL Pin
wilche17-Jun-02 14:35
wilche17-Jun-02 14:35 
GeneralRe: STL Pin
Le centriste17-Jun-02 16:17
Le centriste17-Jun-02 16:17 
GeneralRe: STL Pin
Christian Graus17-Jun-02 20:32
protectorChristian Graus17-Jun-02 20:32 
GeneralCan't profile from MSDEV98 Pin
Jonathan Gilligan17-Jun-02 13:27
Jonathan Gilligan17-Jun-02 13:27 
GeneralProblem Addressed Pin
Jonathan Gilligan17-Jun-02 14:26
Jonathan Gilligan17-Jun-02 14:26 
GeneralRe: Problem Addressed Pin
17-Jun-02 14:43
suss17-Jun-02 14:43 
GeneralFiltering a image ! :suss: Pin
Hadi Rezaee17-Jun-02 12:22
Hadi Rezaee17-Jun-02 12:22 
GeneralRe: Filtering a image ! :suss: Pin
Christian Graus17-Jun-02 12:54
protectorChristian Graus17-Jun-02 12:54 
GeneralRe: Filtering a image ! :suss: Pin
Hadi Rezaee19-Jun-02 4:30
Hadi Rezaee19-Jun-02 4:30 
GeneralCPropertySheet and its "Apply" button Pin
Abin17-Jun-02 12:14
Abin17-Jun-02 12:14 
GeneralRe: CPropertySheet and its "Apply" button Pin
Le centriste17-Jun-02 16:22
Le centriste17-Jun-02 16:22 
GeneralThank you, and gimme more... Pin
Abin17-Jun-02 16:41
Abin17-Jun-02 16:41 
GeneralRe: Thank you, and gimme more... Pin
James R. Twine18-Jun-02 3:06
James R. Twine18-Jun-02 3:06 
GeneralThank you Pin
Abin18-Jun-02 7:55
Abin18-Jun-02 7:55 
GeneralError when using free to free memory allocated with malloc. Pin
redeemer17-Jun-02 11:54
redeemer17-Jun-02 11:54 
GeneralRe: Error when using free to free memory allocated with malloc. Pin
Roger Broomfield17-Jun-02 12:49
Roger Broomfield17-Jun-02 12:49 
QuestionHow do i keep colors from changing in resource editor? Pin
redeemer17-Jun-02 11:05
redeemer17-Jun-02 11:05 

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.