Use GCHandles for encoded strings