Have a look at the various existing implementations of the CoinSelector interface. It shouldn't be too difficult to come up with a selector that only selects outputs that pay to a certain address.
On 03/22/2017 05:12 AM, Ramez Az wrote: > Can you please provide some sample program for this implementation? Thanks. > > On Tuesday, March 21, 2017 at 10:10:25 PM UTC+5:30, Andreas Schildbach > wrote: > > You could do this by implementing your own CoinSelector. Bitcoinj by > default always spends the oldest coins first, so it doesn't matter what > address they're currently on. > > > On 03/21/2017 01:03 PM, Ramez Az wrote: > > Hi, > > > > I am trying to transfer/spent some coins from one address in a > > particular wallet to another. I am able to transfer the coins, but > not > > able to find the way to mention the address from where the coin > should > > be spent instead of spending from the address decided by the wallet > > itself. Is there any way to achieve this using bitcoinj APIs. > > > > Thanks, > > Ramesh A > > > > -- > > 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 [email protected] > > <mailto:[email protected]>. > > For more options, visit https://groups.google.com/d/optout > <https://groups.google.com/d/optout>. > > > -- > 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 [email protected] > <mailto:[email protected]>. > For more options, visit https://groups.google.com/d/optout. -- 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 [email protected]. For more options, visit https://groups.google.com/d/optout.
