Here a sample to illustrate :
(launch sourcescript.tbasic)
Archive.zip
Hi,
do varptr return real memory adress or something 'tb internal' as codeptr do ?
I didn't understand this:
I have two instance of thinbasic scripts. varptr gives me an adress for a variable in the script 1. If I peek(long, adress) at the same adress in script 2, thinbasic doesn't return the good value.
ThinBasic 1.11.6.0 ALPHA - Windows 8.1 x64
Here a sample to illustrate :
(launch sourcescript.tbasic)
Archive.zip
ThinBasic 1.11.6.0 ALPHA - Windows 8.1 x64
Hi Sebastian,
by default, it is not allowed to access memory of independent process from other independent process.
VARPTR of given value in one process does not point to the same location in another process.
I don't say it is not possible to access other process memory - but if you want avoid being triggered as false positive by AV programs, I would suggest to avoid it.
If you need to exchange data between two processes, I would suggest to have a look at cMMF (thinBASIC helper for memory mapped files).
Petr
Learn 3D graphics with ThinBASIC, learn TBGL!
Windows 10 64bit - Intel Core i5-3350P @ 3.1GHz - 16 GB RAM - NVIDIA GeForce GTX 1050 Ti 4GB
Bookmarks