Results 1 to 16 of 16

Thread: Read memory - Reading string from address

Hybrid View

  1. #1
    Cumbrian Milk's Avatar
    Join Date
    Jan 2007
    Location
    0xDEADBEEF
    Posts
    2,448

    Re: Read memory - Reading string from address

    I never tested them sorry if I messed them up.

    I used buf() = vbnullstring to show a fail state by returning an array with a Ubound of -1 and an Lbound of 0. It appears that StrConv can't handle that although it can handle a null string (which is what the fail state buf() converts to). To avoid the error you could use...
    Code:
    sTest = StrConv(CStr(ReadProcessBytes(hWnd, Address, Size)), vbUnicode)
    Unfortunately if buf() is in it's fail state then the function has failed somehow, either because one or more of the parameters is incorrect or more likely because readsz has returned 0 where it should return the number of bytes read, which all going well should be the same as Size.

    Can you show me the declares you have used for Read/WriteProcessMemory and can you confirm that you are not using On Error Resume Next.

    Edit: No need, I see the code you posted is just a cut and paste from Allapi, I assume you are using the declares from there as well. I'll test them at some point later today to see If I notice anything.
    Last edited by Milk; Feb 1st, 2010 at 05:43 AM.
    W o t . S i g

  2. #2

    Thread Starter
    Member
    Join Date
    Mar 2007
    Posts
    47

    Re: Read memory - Reading string from address

    thanks for helping, ill get working on this when i get home. look forward to ur outcome

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width