You were nearly right, but I think the "literal" command is a client-side command that would tell your command-line client to send whatever else you typed to the server. In other words, it would've sent "site mapin text(filekind=data, recordlength 27)" to the server.
You therefore should be using:
ftpConnection.InvokeFTPCommand("site mapin text(filekind=data, recordlength 27)", "200");
The 200 is the most common reply-code meaning that everything went well, but the server may send back something else. To see what the server returns, check what your command-line version returns and use that value.
Alternatively you can use:
ftpConnection.InvokeFTPCommand("mapin text(filekind=data, recordlength 27)");
This version implicitly does the "site" command and doesn't check the reply-code, but returns an FTPReply object for you to check yourself (if you want).
- Hans (EDT)