Private Declare Sub CopyMemory Lib "kernel32.dll" Alias "RtlMoveMemory" (ByRef Destination As Any, ByRef Source As Any, ByVal Length As Long)
Sub test1()
Const SECRET_PASSWORD As String = "Secret Squirrel"
Dim c As Class1
Set c = GetClass1
c.SetPassword SECRET_PASSWORD
Dim instancePointer As Long
instancePointer = ObjPtr(c) + &H34
Dim fieldPointer As Long
CopyMemory fieldPointer, ByVal instancePointer, 4&
Dim stringLengthPointer As Long
stringLengthPointer = fieldPointer - 4