Printing memory

So I want to create a program that will print out every memory location and the value located on that address. How would I do this?

I'm well aware I need to use pointers, I was thinking maybe a concactinated loop that creates/modifies a string and then casting it to an integer that I can make equal to another integer and then cout<<&integer;.

Any ideas/thoughts/concerns?
You may have asked something similar @ the MSDN forums and I may have already answer you, but just in case here it goes:

Google up "virtual address space" to learn why you cannot access the memory contents of other executables running. Having said that, with sufficient privileges you can use ReadProcessMemory() to read specific locations of virtual memory in other executables. Google that up too.

If you do not want to read other processes' memory, then you can just attempt to read each memory address in the process address space. Some you'll be able to read, some you won't. You'll probably required structure error handling to avoid bad crashes. Google that up too.

I don't go into more detail because the topics involved are extensive. Best if you read about the subject from more authoritative sources.
Topic archived. No new replies allowed.