I followed this tutorial, but readprocessmemory spikes up explorer process memory each time it is called. What could be the reason and how to resolve that?
http://www.vbforums.com/showthread.p...ar-button-text
Printable View
I followed this tutorial, but readprocessmemory spikes up explorer process memory each time it is called. What could be the reason and how to resolve that?
http://www.vbforums.com/showthread.p...ar-button-text
In that link, post #3, line 68 is what I suspect is the faulty line:
Suggest changing from: VirtualFreeEx 0, lpCaption, 0, MEM_RELEASE
to: VirtualFreeEx hProcess, lpCaption, 0, MEM_RELEASE
How now?
That line of code should've helped. You may have other areas in your code that is not freeing the memory?
You said this time, still failing? What is failing? Is this being run on a 64 bit O/S?
I don't have access to a 64 bit machine so I can't offer any possible solutions. I don't know if part of the problem is talking between 32 & 64 bit processes using readprocessmemory or not. Haven't done any research as to whether the pointers & data would be cleaned up as expected.
Are you using the exact code at that link? If not, may want to show us your complete routine that you are using?
In that link, I see another problem. Probably a dead issue for now, but one of the constants is declared wrong.
Line 34: Const MEM_RELEASE = &H8000
should be: Const MEM_RELEASE = &H8000&
That trailing ampersand is huge in this case