Article View: comp.os.ms-windows.programmer.tools.mfc
Article #81Re: Linked Lists
From: John Lutz
Date: Thu, 11 Apr 1996 02:42
Date: Thu, 11 Apr 1996 02:42
26 lines
1354 bytes
1354 bytes
In article <31667AC8.4EE2@mindlink.bc.ca>, Blake Kadatz <blake_kadatz@mindlink.bc.ca> wrote: >John Lutz wrote: >> >> I would like to store all the objects in a linked list for a given window. I >> would like for the linked list to handle the dynamic allocation of these >> object and return the pointer to the subclass that is allocating the objects >> on the linked list. I would like for the linked list class to delete all >> objects dynamically. > >Have you tried CObList or CPtrList? These classes don't automatically >delete the object for you, but when you remove the object from the list, >it returns you a pointer. Easy -- just delete that pointer. > Opps, I forgot to mention it's under Visual C++ 4.0 but not using MFC. John PS- Also, this project doesn't include MFC, how difficult would it be to implemente MFC (linking in a .LIB file)? I'm somewhat new to MFC/VC++ but not to C++.
Technical Details
Message-ID:
<4khrin$m41@news2.cts.com>Path:
arc1-ca.pugleaf.net!newshub.cts.com!nsReferences:
<4k2kom$k5r@news2.cts.com> <31667AC8.4EE2@mindlink.bc.ca>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!newshub.cts.com!ns From: tsk@cts.com (John Lutz) Newsgroups: comp.os.ms-windows.programmer.tools.mfc,comp.lang.c++ Subject: Re: Linked Lists Date: 11 Apr 1996 02:42:31 GMT Organization: Cathedral Software, Inc. Message-ID: <4khrin$m41@news2.cts.com> References: <4k2kom$k5r@news2.cts.com> <31667AC8.4EE2@mindlink.bc.ca> NNTP-Posting-Host: tsk.cts.com X-Newsreader: News Xpress Version 1.0 Beta #4