I'm trying to modify the wallettemplate project and one thing I can't get 
to change is the displayed address, which is currently a testnet bech32 
public key hash address, and I would like to see a testnet public key hash 
to be able to check that address in the blockchain explorers.
In the Main class, I changed this line: public static final 
Script.ScriptType PREFERRED_OUTPUT_SCRIPT_TYPE = Script.ScriptType.P2WPKH; 
to: public static final Script.ScriptType PREFERRED_OUTPUT_SCRIPT_TYPE = 
Script.ScriptType.P2PKH;but it doesn't change the displayed address. What 
is the right way to change it? 

Also, I've seen that getting the sender's address to appear in the 
transactions list is something discouraged by some, but how can one now 
(using bitcoinj) who sent a transaction to them?
I understand the ambiguity involved, but reading this 
<https://groups.google.com/forum/#!searchin/bitcoinj/getAddressFromP2PKHScript()|sort:date/bitcoinj/02mDeOiHeuk/BDmr-KulBgAJ>,
 I 
don't understand if the code solution provided is for getting the sender's 
address or the receiver's one. Maybe is a concept I don't fully understand, 
so I'd be grateful if someone could shed a light on this.

-- 
You received this message because you are subscribed to the Google Groups 
"bitcoinj" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to bitcoinj+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to