Added key and close.

When using 'key' it saves the used key to %key%