Click here to Skip to main content
15,905,073 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralEnabling active x component :(( :(( Pin
act_x8-Apr-02 12:01
act_x8-Apr-02 12:01 
GeneralRe: Enabling active x component :(( :(( Pin
Joaquín M López Muñoz8-Apr-02 12:10
Joaquín M López Muñoz8-Apr-02 12:10 
Generalforward variable argument lists Pin
8-Apr-02 11:47
suss8-Apr-02 11:47 
GeneralRe: forward variable argument lists Pin
Joaquín M López Muñoz8-Apr-02 11:57
Joaquín M López Muñoz8-Apr-02 11:57 
GeneralRe: forward variable argument lists Pin
9-Apr-02 6:30
suss9-Apr-02 6:30 
GeneralRe: forward variable argument lists Pin
Alexandru Savescu8-Apr-02 22:31
Alexandru Savescu8-Apr-02 22:31 
Generalconstructor problem (newbie) Pin
marcela8-Apr-02 11:39
marcela8-Apr-02 11:39 
GeneralRe: constructor problem (newbie) Pin
Joaquín M López Muñoz8-Apr-02 11:39
Joaquín M López Muñoz8-Apr-02 11:39 
Hola Marcela!

When you write
m_categoria = nom;
you're accessing the internal representation (as a LPCTSTR) of the CString nom. m_categoria will be OK as long as these two conditions hold:
  1. nom is not modified.
  2. nom is not destroyed.
The latter is precisely what's happening when the constructor exits, so m_categoria will basically point to some junk area in the heap from now on. Best way to handle this is declaring m_categoria as a CString itself, so that it keeps and manages its own memory.

Joaquín M López Muñoz
Telefónica, Investigación y Desarrollo
GeneralRe: constructor problem (newbie) Pin
Christian Graus8-Apr-02 11:41
protectorChristian Graus8-Apr-02 11:41 
GeneralRe: constructor problem (newbie) Pin
Joaquín M López Muñoz8-Apr-02 11:46
Joaquín M López Muñoz8-Apr-02 11:46 
GeneralRe: constructor problem (newbie) Pin
marcela8-Apr-02 11:49
marcela8-Apr-02 11:49 
GeneralTool tip text Pin
8-Apr-02 11:11
suss8-Apr-02 11:11 
GeneralRe: Tool tip text Pin
Joaquín M López Muñoz8-Apr-02 11:20
Joaquín M López Muñoz8-Apr-02 11:20 
GeneralRe: Tool tip text Pin
Alexandru Savescu8-Apr-02 22:22
Alexandru Savescu8-Apr-02 22:22 
Generaltemplate members Pin
Jamie Hale8-Apr-02 10:25
Jamie Hale8-Apr-02 10:25 
GeneralRe: template members Pin
Joaquín M López Muñoz8-Apr-02 10:25
Joaquín M López Muñoz8-Apr-02 10:25 
GeneralRe: template members Pin
Jamie Hale9-Apr-02 4:53
Jamie Hale9-Apr-02 4:53 
GeneralRe: template members Pin
Joaquín M López Muñoz9-Apr-02 5:05
Joaquín M López Muñoz9-Apr-02 5:05 
GeneralRe: template members Pin
Jamie Hale9-Apr-02 5:17
Jamie Hale9-Apr-02 5:17 
GeneralRe: template members Pin
Joaquín M López Muñoz9-Apr-02 5:41
Joaquín M López Muñoz9-Apr-02 5:41 
GeneralRe: template members Pin
Jamie Hale9-Apr-02 5:45
Jamie Hale9-Apr-02 5:45 
GeneralRe: template members Pin
Joaquín M López Muñoz9-Apr-02 6:12
Joaquín M López Muñoz9-Apr-02 6:12 
GeneralRe: template members Pin
Jamie Hale9-Apr-02 6:38
Jamie Hale9-Apr-02 6:38 
GeneralRe: template members Pin
Joaquín M López Muñoz9-Apr-02 6:15
Joaquín M López Muñoz9-Apr-02 6:15 
GeneralRe: template members Pin
Jamie Hale9-Apr-02 6:39
Jamie Hale9-Apr-02 6:39 

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.