user27532: I am trying to get the MPK of a wallet using bitcoinj. Can I get the DeterministicSeed, which is the seed of the wallet and get the MnemonicCode of 12 words. But I can't get the MPK. As I can make it using bitcoinj?

user27532: I have found the way to do it:
    DeterministicKey extendedKey = wallet.getWatchingKey();
    String mpk = extendedKey.serializePubB58(wallet.getParams());


27532: <p>I am trying to get the MPK of a wallet using bitcoinj. Can I get the DeterministicSeed, which is the seed of the wallet and get the MnemonicCode of 12 words. But I can't get the MPK. As I can make it using bitcoinj?</p>
 27532: <p>I have found the way to do it:</p>

<pre><code>    DeterministicKey extendedKey = wallet.getWatchingKey();
    String mpk = extendedKey.serializePubB58(wallet.getParams());
</code></pre>
