Click here to Skip to main content
15,927,344 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralSetItemData, GetItemData Pin
elephantstar5-Apr-05 15:19
elephantstar5-Apr-05 15:19 
GeneralRe: SetItemData, GetItemData Pin
Christian Graus5-Apr-05 16:06
protectorChristian Graus5-Apr-05 16:06 
GeneralRe: SetItemData, GetItemData Pin
DasdaDAS5-Apr-05 21:01
DasdaDAS5-Apr-05 21:01 
GeneralRe: SetItemData, GetItemData Pin
elephantstar6-Apr-05 8:14
elephantstar6-Apr-05 8:14 
GeneralRe: SetItemData, GetItemData Pin
toxcct5-Apr-05 21:54
toxcct5-Apr-05 21:54 
GeneralRe: SetItemData, GetItemData Pin
Michael Dunn6-Apr-05 2:03
sitebuilderMichael Dunn6-Apr-05 2:03 
Generalneed help with a simple MFC question Pin
stuckupfool5-Apr-05 14:20
stuckupfool5-Apr-05 14:20 
GeneralRe: need help on the program data structure Pin
Christian Graus5-Apr-05 13:07
protectorChristian Graus5-Apr-05 13:07 
GeneralRe: need help on the program data structure Pin
Anonymous6-Apr-05 9:32
Anonymous6-Apr-05 9:32 
GeneralRe: need help on the program data structure Pin
Cedric Moonen5-Apr-05 20:13
Cedric Moonen5-Apr-05 20:13 
GeneralRe: need help on the program data structure Pin
toxcct5-Apr-05 20:56
toxcct5-Apr-05 20:56 
Generalemessaging client Pin
jessiesrage5-Apr-05 11:28
jessiesrage5-Apr-05 11:28 
GeneralRe: emessaging client Pin
David Crow5-Apr-05 11:39
David Crow5-Apr-05 11:39 
GeneralRe: emessaging client Pin
ThatsAlok5-Apr-05 18:16
ThatsAlok5-Apr-05 18:16 
GeneralChanging ComboBox selection by text editing Pin
Ultimate Newbie5-Apr-05 10:53
sussUltimate Newbie5-Apr-05 10:53 
GeneralRe: Changing ComboBox selection by text editing Pin
David Crow5-Apr-05 11:43
David Crow5-Apr-05 11:43 
Generalemail client Pin
_tasleem5-Apr-05 9:52
_tasleem5-Apr-05 9:52 
GeneralRe: email client Pin
David Crow5-Apr-05 11:45
David Crow5-Apr-05 11:45 
GeneralPersistent GlobalAlloc or "Resource Leaks on purpose!" Pin
iwasiunknown5-Apr-05 9:22
iwasiunknown5-Apr-05 9:22 
Anyone know what Win32 technology will allow me to create a global memory structure (a couple of meg or so) and have it stay in memory after the creating application has ended? There is no reason for the structure to cross reboots.

I don’t want to use the persistent technologies like the registry or the hard drive. In the old 16 bit days, I would just GlobalAlloc a couple of Meg and write the handle to the atom table and use it when I need to or something like that. But today…when an application exits all resources it allocated are released (unless another application opened the same resource), which is pretty cool, but not what I’m looking for.

Here’s what I’ve tried and the problems with them:
1) GlobalAlloc – deleted on program exit
2) Volatile registry – best practices says not really good for more than 2k of data
3) Memory file via CreateFileMapping – deleted on program exit
4) Global Atoms – not big enough, only 16k entries and each entry is limited to 256 bytes

My limitations are that I have to rely on whatever is already on the machine and can't install anything...in other words...static linking and straight Win32.

Any ideas?
GeneralRe: Persistent GlobalAlloc or "Resource Leaks on purpose!" Pin
Shog95-Apr-05 13:55
sitebuilderShog95-Apr-05 13:55 
GeneralRe: Persistent GlobalAlloc or "Resource Leaks on purpose!" Pin
iwasiunknown7-Apr-05 4:41
iwasiunknown7-Apr-05 4:41 
Generalneed help please: error LNK2001 urgent Pin
xeru_slash5-Apr-05 9:21
xeru_slash5-Apr-05 9:21 
GeneralRe: need help please: error LNK2001 urgent Pin
David Crow5-Apr-05 11:48
David Crow5-Apr-05 11:48 
GeneralRe: need help please: error LNK2001 urgent Pin
xeru_slash5-Apr-05 22:05
xeru_slash5-Apr-05 22:05 
GeneralRe: need help please: error LNK2001 urgent Pin
ThatsAlok5-Apr-05 22:28
ThatsAlok5-Apr-05 22:28 

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.