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

C / C++ / MFC

 
JokeRe: OT Pin
James R. Twine1-Aug-07 7:25
James R. Twine1-Aug-07 7:25 
JokeRe: OT Pin
Eytukan1-Aug-07 7:30
Eytukan1-Aug-07 7:30 
JokeRe: OT Pin
ThatsAlok5-Aug-07 23:43
ThatsAlok5-Aug-07 23:43 
GeneralRe: OT Pin
Eytukan5-Aug-07 23:50
Eytukan5-Aug-07 23:50 
GeneralRe: OT Pin
Michael Dunn1-Aug-07 7:57
sitebuilderMichael Dunn1-Aug-07 7:57 
GeneralRe: OT Pin
Cedric Moonen1-Aug-07 7:59
Cedric Moonen1-Aug-07 7:59 
GeneralRe: OT Pin
Michael Dunn1-Aug-07 8:10
sitebuilderMichael Dunn1-Aug-07 8:10 
GeneralRe: OT Pin
Rage1-Aug-07 20:50
professionalRage1-Aug-07 20:50 
GeneralRe: Launching Paint from different OS Pin
Cedric Moonen1-Aug-07 4:01
Cedric Moonen1-Aug-07 4:01 
GeneralRe: Launching Paint from different OS Pin
Jonathan [Darka]1-Aug-07 4:13
professionalJonathan [Darka]1-Aug-07 4:13 
GeneralRe: Launching Paint from different OS Pin
ThatsAlok5-Aug-07 23:44
ThatsAlok5-Aug-07 23:44 
QuestionAdd text to Tooltip for a XML file Pin
AeJai1-Aug-07 2:52
AeJai1-Aug-07 2:52 
AnswerRe: Add text to Tooltip for a XML file Pin
Iain Clarke, Warrior Programmer2-Aug-07 0:28
Iain Clarke, Warrior Programmer2-Aug-07 0:28 
QuestionHow modifie string table in Run tIme. Pin
birajendu1-Aug-07 2:50
birajendu1-Aug-07 2:50 
AnswerRe: How modifie string table in Run tIme. Pin
David Crow1-Aug-07 2:52
David Crow1-Aug-07 2:52 
GeneralRe: How modifie string table in Run tIme. Pin
birajendu1-Aug-07 2:59
birajendu1-Aug-07 2:59 
GeneralRe: How modifie string table in Run tIme. Pin
David Crow1-Aug-07 3:03
David Crow1-Aug-07 3:03 
AnswerRe: How modifie string table in Run tIme. Pin
toxcct1-Aug-07 2:55
toxcct1-Aug-07 2:55 
GeneralRe: How modifie string table in Run tIme. Pin
birajendu1-Aug-07 3:02
birajendu1-Aug-07 3:02 
GeneralRe: How modifie string table in Run tIme. Pin
toxcct1-Aug-07 3:03
toxcct1-Aug-07 3:03 
GeneralRe: How modifie string table in Run tIme. Pin
birajendu1-Aug-07 3:07
birajendu1-Aug-07 3:07 
GeneralRe: How modifie string table in Run tIme. Pin
toxcct1-Aug-07 3:12
toxcct1-Aug-07 3:12 
GeneralRe: How modifie string table in Run tIme. Pin
birajendu1-Aug-07 3:17
birajendu1-Aug-07 3:17 
GeneralRe: How modifie string table in Run tIme. Pin
toxcct1-Aug-07 3:20
toxcct1-Aug-07 3:20 
GeneralRe: How modifie string table in Run tIme. Pin
James R. Twine1-Aug-07 3:19
James R. Twine1-Aug-07 3:19 
   You do not search at runtime, you bring them all into memory at startup.  Even if you had 32767 strings with a length of 64 each, that would only require 2MB of memory - not a lot in today's world especially when it is only needs to be managed once at startup and once at shutdown.

  If you design the file correctly, each string has a specific index, you store offsets into the file for each index, place the index at the start of the file, and you store the strings with their terminating NUL characters.

   So at startup, you memory-map the strings file, read the index to determine the start of each (indexed) string, and since it contains its terminating NUL, you can use normal string-handling code to copy the strings where needed for display just by starting the copy operation from its offset using the address of the view of the MM file.

   This would require a separate app to edit the strings file, but it would be worth it, IMHO.

   Peace!

-=- James
Please rate this message - let me know if I helped or not!<HR>If you think it costs a lot to do it right, just wait until you find out how much it costs to do it wrong!
Avoid driving a vehicle taller than you and remember that Professional Driver on Closed Course does not mean your Dumb Ass on a Public Road!
See DeleteFXPFiles

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.