Indeed #0 as separator and #0#0 as terminator. But I don't think that was the issue here, although it can be.
Btw, I forgot to add that {$mode delphiunicode} will pick the W versions by default.
And these are since NT2000 (maybe even NT4) always the real versions that are called. The AnsiString A versions are mostly stubs and redirect to the W versions anyway.