by Marius Schmidt (1 Submission)
Category: Coding Standards
Compatability: Visual Basic 5.0
Difficulty: Intermediate
Date Added: Wed 3rd February 2021
Rating: (6 Votes)
This code shows you how to use Real pointers with VB. Everyone who jelled that VB has no pointers is simply wrong! VB arrays are just pointers to memory and it's quite simple to change the address of these pointers. It's pretty usefull for fast memory access without using a crappy CopyMemory call (the CopyMemory way would a) create memory garbage and b) create overhead because data moving is slow [though cpymemory is faster then manually moving data]), though we still need 1 small CopyMemory call but it's just a helper.
API DeclarationsCopyMemory (well, it's just used for a little data moving)
VarPtrArray