Bitcoin Forum

Bitcoin => Project Development => Topic started by: Coding Enthusiast on September 14, 2016, 02:54:14 PM



Title: [C#] Watch Only Bitcoin Wallet. Support SegWit and Forks (V3.2.1)
Post by: Coding Enthusiast on September 14, 2016, 02:54:14 PM
Table of Contents
https://i.imgur.com/9FtfXzM.jpg
__________
  • Introduction (#post_intro)
  • Features (#post_features)
  • Links (#post_links)
  • To Do List (#post_toDo)
  • Updates (#post_updates)

Introduction
This is a simple open source tool which can help users keep track of their bitcoin addresses, balance of each address, bitcoin price and Total balance value in BTC, $ and user's local currency, balances at a specific height.
The main focus will be in keeping this tool light and fast.
https://i.imgur.com/013QHQ0.jpg (https://i.imgur.com/013QHQ0.jpg)

https://i.imgur.com/kskLnGh.jpg (https://i.imgur.com/kskLnGh.jpg)
*Click on the image to see bigger size*
(#post_tocHeader)

Features
  • Capable of holding multiple bitcoin addresses with tags, address and their balances.
  • Validating each address with Base58_encoding and new Bech32 format for Segregated Witness.
  • Using a grid (like excel) to show the list which makes it easy to add/edit/remove items.
  • Import addresses in bulk from file or paste in textbox (seperate by newline).
  • Using different block explorer API services to update balances.
  • See the total bitcoin amount in BTC, USD and user defined local currency.
  • USD value can be retrieved from Bitfinex.com or Btc-e.com exchanges using their API.
  • View balance at a specific block height. This is useful for checking how much you owned when a fork like bitcoin cash happened.
(#post_tocHeader)


Links
Source code on GitHub: https://github.com/Coding-Enthusiast/Watch-Only-Bitcoin-Wallet
Donate Bitcoin: 1Q9swRQuwhTtjZZ2yguFWk7m7pszknkWyk (bitcoin:1Q9swRQuwhTtjZZ2yguFWk7m7pszknkWyk)
SegWit: bc1q3n5t9gv40ayq68nwf0yth49dt5c799wpld376s (bitcoin:bc1q3n5t9gv40ayq68nwf0yth49dt5c799wpld376s)

https://i.imgur.com/oz9UvFM.png (https://i.imgur.com/oz9UvFM.png)   https://i.imgur.com/UMGQ2Ck.jpg (https://i.imgur.com/UMGQ2Ck.jpg)
(#post_tocHeader)


To Do List (aka future features!)
  • [✓]Add other block explorer's APIs and the ability to switch between them.
  • [✓]Add a couple of bitcoin exchanges API for receiving the live bitcoin price.
  • [✓]Add Base58CheckSum check for the input bitcoin address to prevent typos.
  • [✓]Change the style from TextBox to a ListView to make adding unlimited addresses easier.
  • [✓]Handling possible Excretions properly.
  • [✓]Adding the option to create a raw unsigned transaction.(A separate project! Link (https://bitcointalk.org/index.php?topic=1701507.0))
  • [✓]Add unit test.
(#post_tocHeader)

Feel free to post your request, feedback, suggestion,... in the comments here or on GitHub (https://github.com/Coding-Enthusiast/Watch-Only-Bitcoin-Wallet/issues)


Title: Re: [C#][Github] Watch Only Bitcoin Wallet. Keep track of balance and price.
Post by: Coding Enthusiast on October 06, 2016, 01:55:11 PM
Major Updates (see commits on github for details)
  • [2016-09-14] Added Icon, Links and some code cleanup
  • [2016-09-09] Initial Commit
  • [2016-10-06] Changed GUI from old TextBox mode (https://i.imgur.com/6IQSPqW.jpg) to ListView mode (https://i.imgur.com/6PUl3q1.jpg) for a better look.
  • [2016-10-09] Version 1.1.0 released.
  • [2016-12-05] Version 2.0.0 released.
  • [2017-02-03] Version 2.1.0 released. (Code improved) Now there is only two assemblies.
  • [2017-06-25] Version 2.2.0 released. Lots of code improvement.
  • [2017-12-12] Version 2.3.0 released. New block explorer and balance column is now color coded.
  • [2018-01-04] Version 2.4.0 released. Added fork balance.
  • [2018-01-29] Version 3.0.0 released. Added support of Bech32 SegWit address format.
  • [2018-02-16] Version 3.1.0 released. Added an option to import addresses from file/text in bulk.
(#post_tocHeader)


Title: Re: [C#][Github] Watch Only Bitcoin Wallet. Keep track of balance and price.
Post by: Patatas on October 06, 2016, 06:47:15 PM
As respectfully I'd like to appreciate your efforts for putting the stuff on github,I'd want to point out the main factor which would make your app absolutely a waste of time.That is,the requirements!

 -No everybody uses web wallets,electrum pretty much gives the same service to watch my wallet addresses.
 -Any block explorer would give the results instantly after putting a bitcoin address.Do you really think someone would
 take the pain of keep a 3rd party app running and refreshing the stuff to get the latest results ? I doubt it.
 -I'd give you one for the efforts but practically,I don't think the app would make anything simpler to use.


Title: Re: [C#][Github] Watch Only Bitcoin Wallet. Keep track of balance and price.
Post by: Youresioure on October 06, 2016, 06:56:21 PM
Thank you for uploading your BTC wallet to GitHub! I'm learning C# in my free time and I keep your upload an useful resource. Since it's open-source, I hope I'll be able to contribute some nice features in it soon.


Title: Re: [C#][Github] Watch Only Bitcoin Wallet. Keep track of balance and price.
Post by: Coding Enthusiast on October 08, 2016, 06:33:40 AM
Thanks for your feedbacks.

As respectfully I'd like to appreciate your efforts for putting the stuff on github,

This is the main reason. to make the code open source, get feedback on the code and learn more about coding (look at my name ;))

Quote
I'd want to point out the main factor which would make your app absolutely a waste of time.That is,the requirements!

I enjoy coding so even if others don't find it useful, I am learning a lot of things in the process and I find it useful for myself that is why I created this in the first plce.
2 weeks ago I couldn't imagine designing the Xaml like what you see in the first post.
A month ago I didn't know how to use Github now i am pushing commits properly to my new branch.
A couple of months ago i had no idea how to use API and now i have this as my tiny side-project and 4 other projects 1 of which is a trading utilities which i am up to 2000 lines of code.

Quote
-No everybody uses web wallets,electrum pretty much gives the same service to watch my wallet addresses.

It is mainly about the size, Electrum is lightweight but it is still 50 MB installation file + 35 MB headers and wallets files.
this project is 1 MB installation file + < 3KB wallet file

Also i personally like to keep track of the value of my bitcoin. If you look at the left side of the GUI you see three TextBoxes for total bitcoin balance and the value of it in USD and local currency which I can't get in Electrum.

Quote
-Any block explorer would give the results instantly after putting a bitcoin address.Do you really think someone would
 take the pain of keep a 3rd party app running and refreshing the stuff to get the latest results ? I doubt it.

It is more like a log book to keep track of ALL your money (public keys)!
For example I have multiple bitcoin addresses which I want to keep them all in one place and not have to copy each address, open a browser and paste one by one to see what the balances are and then open up a calculator to calculate how much it is worth especially in my local currency!



Thank you for uploading your BTC wallet to GitHub! I'm learning C# in my free time and I keep your upload an useful resource. Since it's open-source, I hope I'll be able to contribute some nice features in it soon.

If I see more C♯ Enthusiasts around here I may publish more of my projects on Github.
I'll be glad to see your contributions and help you in any way i can in learning C♯.


Title: Re: [C#][Github] Watch Only Bitcoin Wallet. Keep track of balance and price.
Post by: apoorvlathey on October 09, 2016, 05:24:38 PM
As respectfully I'd like to appreciate your efforts for putting the stuff on github,I'd want to point out the main factor which would make your app absolutely a waste of time.That is,the requirements!

 -No everybody uses web wallets,electrum pretty much gives the same service to watch my wallet addresses.
 -Any block explorer would give the results instantly after putting a bitcoin address.Do you really think someone would
 take the pain of keep a 3rd party app running and refreshing the stuff to get the latest results ? I doubt it.
 -I'd give you one for the efforts but practically,I don't think the app would make anything simpler to use.

I think this software must be upgraded to an online service. It would then become more convenient to use than to install 3rd party software. It would practically be more easy to view all the addresses's balances in one place instead of using blockchain explorer for each and every address.


Title: Re: [C#][Github] Watch Only Bitcoin Wallet. Keep track of balance and price.
Post by: semobo on October 09, 2016, 08:44:52 PM
Don't get discouraged. Open source software is much appreciated and needed. Keep up the good work. I'm a C# developer myself and always love seeing new C# projects pop up. Would love to help you in any way I can.


Title: Re: [C#][Github] Watch Only Bitcoin Wallet. Keep track of balance and price.
Post by: OROBTC on October 09, 2016, 09:43:50 PM
...

I am not a programmer, but I do very much appreciate those who add value with open-source software.  "Adding value" is what it's all about (in making progress).

So: clap, clap  :) 

An idea of a future project that I would like to see would be another "Taint Analysis" tool that would show "taint" (connections) between BTC wallets and BTC transfers.  Depending on blockchain.info (as a monoploy on this type of tool) makes me a tad queasy...


Title: Re: [C#][Github] Watch Only Bitcoin Wallet. Keep track of balance and price.
Post by: klaaas on October 09, 2016, 10:01:24 PM
Great to see you share your code ! could be handy if you got multiple wallets to keep an eye on.
I was planning to do the same concept in php if i can find the spear time.


Title: Re: [C#][Github] Watch Only Bitcoin Wallet. Keep track of balance and price.
Post by: Coding Enthusiast on October 10, 2016, 03:48:38 AM
♯I think this software must be upgraded to an online service.♯

There is already a good service you can use for "watch-only" purposes called blockchain.info and they even send you an SMS free of charge.

♯It would then become more convenient to use than to install 3rd party software.♯

This is open source, you don't install anything. You go through the code and if you understood the code, you compile it yourself.

Don't get discouraged. Open source software is much appreciated and needed. Keep up the good work. I'm a C# developer myself and always love seeing new C# projects pop up. Would love to help you in any way I can.

Thank you for your kind words. I am still a beginner but I have been improving a lot. I've already gotten some good feedback on my code on Reddit (https://www.reddit.com/r/csharp/comments/56m46e/beginnerreviewcriticize_requestgithub_watch_only/). But I am always looking for criticism and/or contribution in any way.

An idea of a future project that I would like to see would be another "Taint Analysis" tool that would show "taint" (connections) between BTC wallets and BTC transfers.  Depending on blockchain.info (as a monoploy on this type of tool) makes me a tad queasy...

This sounds like a very good idea. I am working on 4 different projects these days 2 of which you can see here (the wallet and making transactions: Raw unsigned and also CPFP transactions) but I will add it to my queue.



I will update the code this week with all the feedback I have received so far, and most importantly I will add documentation to make it easier to understand.


Title: Re: [C#][Github] Watch Only Bitcoin Wallet. Keep track of balance and price.
Post by: OROBTC on October 10, 2016, 04:44:14 AM
♯I think this software must be upgraded to an online service.♯

There is already a good service you can use for "watch-only" purposes called blockchain.info and they even send you an SMS free of charge.

♯It would then become more convenient to use than to install 3rd party software.♯

This is open source, you don't install anything. You go through the code and if you understood the code, you compile it yourself.

Don't get discouraged. Open source software is much appreciated and needed. Keep up the good work. I'm a C# developer myself and always love seeing new C# projects pop up. Would love to help you in any way I can.

Thank you for your kind words. I am still a beginner but I have been improving a lot. I've already gotten some good feedback on my code on Reddit (https://www.reddit.com/r/csharp/comments/56m46e/beginnerreviewcriticize_requestgithub_watch_only/). But I am always looking for criticism and/or contribution in any way.

An idea of a future project that I would like to see would be another "Taint Analysis" tool that would show "taint" (connections) between BTC wallets and BTC transfers.  Depending on blockchain.info (as a monoploy on this type of tool) makes me a tad queasy...

This sounds like a very good idea. I am working on 4 different projects these days 2 of which you can see here (the wallet and making transactions: Raw unsigned and also CPFP transactions) but I will add it to my queue.



I will update the code this week with all the feedback I have received so far, and most importantly I will add documentation to make it easier to understand.



It's guys like you who make the world progress.  I hope that when the time comes that you make some serious coin (Bitcoin?  smile).

There is a lot about the "New Economy" that I still do not well understand (how do you get paid for open-source work, etc.).  But, coding that is open to public review, and with getting notice as author of it, should work out well for you.

Bravo.



Title: Re: [C#][Github] Watch Only Bitcoin Wallet. Keep track of balance and price.
Post by: Coding Enthusiast on October 10, 2016, 04:52:50 AM
♯There is a lot about the "New Economy" that I still do not well understand (how do you get paid for open-source work, etc.). ♯

Open source means you are doing it for free, especially when you release under MIT license (https://github.com/Coding-Enthusiast/Watch-Only-Bitcoin-Wallet/blob/master/LICENSE.md).
And as for making money! I even feel bad for having a donation link, it is more of a habit I think!

Quote
But, coding that is open to public review, and with getting notice as author of it, should work out well for you.

Being able (having the knowledge) to do a tiny thing like this (https://github.com/elendirx/web2web/issues/8) gives me a feeling that I can't buy with all the money in the world ^.^


Title: Re: [C#][Github] Watch Only Bitcoin Wallet. Keep track of balance and price.
Post by: Dabs on October 19, 2016, 01:19:41 PM
How to compile this?


Title: Re: [C#][Github] Watch Only Bitcoin Wallet. Keep track of balance and price.
Post by: Coding Enthusiast on October 19, 2016, 03:15:45 PM
How to compile this?

You need Visual Studio that supports .Net Framework 4.5 and up so at least Visual Studio 2013.

You can download it from here: https://www.visualstudio.com/downloads/

Also as it is said in the GitHub you will need a Nuget package called Newtonsoft.Json (https://www.nuget.org/packages/newtonsoft.json/)
Install with
Code:
Install-Package Newtonsoft.Json

Also keep an eye out, I will soon release a newer version with a little bit better look and easier address edit and a much better code behind following the MVVM pattern.


Title: Re: [C#][Github] Watch Only Bitcoin Wallet. Keep track of balance and price.
Post by: btc_enigma on October 20, 2016, 05:48:30 AM
Good job. Perhaps you can create an android version too.


Title: Re: [C#][Github] Watch Only Bitcoin Wallet. Keep track of balance and price.
Post by: Coding Enthusiast on October 20, 2016, 11:51:37 AM
Good job. Perhaps you can create an android version too.

Thanks.
I have it in my future plans, but the problem is I don't have an android so it would be a bit hard for me to test since I have never done it before, but I will do it eventually.


Title: Re: [C#][Github] Watch Only Bitcoin Wallet. Keep track of balance and price.
Post by: apoorvlathey on October 20, 2016, 02:27:17 PM
Good job. Perhaps you can create an android version too.

Thanks.
I have it in my future plans, but the problem is I don't have an android so it would be a bit hard for me to test since I have never done it before, but I will do it eventually.

Don't worry if you don't have android device, you can still test and run your app on android emulator on a pc.
Android studio by google, bluestacks, leapdroid are some of the emulators.


Title: Re: [C#][Github] Watch Only Bitcoin Wallet. Keep track of balance and price.
Post by: OmegaStarScream on October 21, 2016, 12:13:18 PM
Good job. Perhaps you can create an android version too.

Thanks.
I have it in my future plans, but the problem is I don't have an android so it would be a bit hard for me to test since I have never done it before, but I will do it eventually.

Since you are writing using C# , you could use Xamarin [ http://xamarin.com/ ] (for both Android & iOS) and you don't have to own an android phone , Visual studio will allow you to run an Android emulator once you execute the code and you could test everything on it (It's going to require a decent RAM & CPU).


Title: Re: [C#][Github] Watch Only Bitcoin Wallet. Keep track of balance and price.
Post by: semobo on October 22, 2016, 12:52:20 AM
I've used Xamarin in the past. It does it's job, sure. The one problem I have with it would be the huge payload for such small apps. You're looking at around 5mb payload before you even write a single line of code.


Title: Re: [C#][Github] Watch Only Bitcoin Wallet. Keep track of balance and price.
Post by: Coding Enthusiast on October 31, 2016, 08:55:37 AM
Version 2 is getting ready for release:
https://i.imgur.com/KUWAN4g.jpg (https://i.imgur.com/KUWAN4g.jpg)

Major new features:
  • Code is following the MVVM pattern now
  • The wallet GUI is using the GridView which gives a more excel like view making it easier to add/edit/remove items.
  • Input validation is added to prevent user from entering an invalid bitcoin address

I want to work a little bit more on the code so I am still not merging this with the main branch. But you can see the development on the MVVM branch (https://github.com/Coding-Enthusiast/Watch-Only-Bitcoin-Wallet/tree/MVVM)
Feel free to give me any suggestions or requests. 


Title: Re: [C#][Github] Watch Only Bitcoin Wallet. Keep track of balance and price.
Post by: avatar_kiyoshi on October 31, 2016, 08:58:26 PM
Nice project.
I have some suggestions here:
- maybe add a recent bitcoin price will be great.
- I want it in android version so bad :D
- notification when a transaction come.


Title: Re: [C#][Github] Watch Only Bitcoin Wallet. Keep track of balance and price.
Post by: Coding Enthusiast on November 01, 2016, 09:20:40 AM
Nice project.
I have some suggestions here:
- maybe add a recent bitcoin price will be great.
- I want it in android version so bad :D
- notification when a transaction come.

- Already made possible from the Settings Window, using bitfinex and btc-e APIs:
https://i.imgur.com/K7XhTJZ.jpg (https://i.imgur.com/K7XhTJZ.jpg)

- Maybe someday ;)
- This is possible with a WebSocket API which I think Blockchain.info has. So i guess that can be done but for the next version.


Title: Re: [C#][Github] Watch Only Bitcoin Wallet. Keep track of balance and price.
Post by: OmegaStarScream on November 01, 2016, 10:12:34 AM
A feature that would be nice to add is when you receive a transaction, It keeps the current price and also  the real-time price. It could be really useful to know how much Bitcoin was worth it in the past and compared to now. Columns should look something like this. (also USD balance should be in the GridView) and settings should allow users to choose what currency they want (USD , EURO , etc.. )

Quote
Name | Address | Balance | USD Balance | Worth when received funds


Title: Re: [C#][Github] Watch Only Bitcoin Wallet. Keep track of balance and price.
Post by: Coding Enthusiast on November 01, 2016, 12:19:06 PM
A feature that would be nice to add is when you receive a transaction, It keeps the current price and also  the real-time price. It could be really useful to know how much Bitcoin was worth it in the past and compared to now. Columns should look something like this. (also USD balance should be in the GridView) and settings should allow users to choose what currency they want (USD , EURO , etc.. )

Quote
Name | Address | Balance | USD Balance | Worth when received funds


For that I am going to need access to price history of each hour or at least a medium price of days. I can't find this on Bitfinex API nor on Btc-e. Did not check any other place for price history though.

I will think about adding a new column for Balance in USD


Title: Re: [C#][Github] Watch Only Bitcoin Wallet. Keep track of balance and price.
Post by: OmegaStarScream on November 02, 2016, 06:47:38 AM
A feature that would be nice to add is when you receive a transaction, It keeps the current price and also  the real-time price. It could be really useful to know how much Bitcoin was worth it in the past and compared to now. Columns should look something like this. (also USD balance should be in the GridView) and settings should allow users to choose what currency they want (USD , EURO , etc.. )

Quote
Name | Address | Balance | USD Balance | Worth when received funds


For that I am going to need access to price history of each hour or at least a medium price of days. I can't find this on Bitfinex API nor on Btc-e. Did not check any other place for price history though.

I will think about adding a new column for Balance in USD

I don't think that's going to be needed , I explained the idea wrong , the "Worth when received funds" should be available in each transaction (If you are going to implement transactions of each address) and not the whole address as they funds are received in different periods so that make it impossible to calculate .

It's possible to make a local database (.XML or SQLite for example) , once the address you are watching receive a transaction you store the price (of that real-time in the database) , So In the GridView , when you see the transaction "Worth when received funds" should be taken from the local database and "Real time" balance should be taken from Blockchain API or somewhere else.


Title: Re: [C#][Github] Watch Only Bitcoin Wallet. Keep track of balance and price.
Post by: doof on November 02, 2016, 11:17:54 PM
Couple of things:  With the class https://github.com/Coding-Enthusiast/Watch-Only-Bitcoin-Wallet/blob/MVVM/WalletServices/PriceServices.cs

If  you have an enum, use it instead of a string in the get method.  Thats what its for.

Code:
public static async Task<decimal> GetPrice(ServiceNames serviceName)

Doing that will prevent the need for this.

Code:
default:
                    price = 0;
                    break;

You shouldn't really do that anyway.  The caller should be treating your method as a black box. If the service doesnt exist, throw an exception.  Don't give the user a heart attack and return a 0 price!

Using a switch statement also means you violate the open closed principal.  You should really use an Interface and have concrete types of "BitFinex" ect.  Which will enable you to mock the call in your unit tests.  Also, the convention is to name async method with async.

Code:
    public interface IPriceClient
    {
        Task<Decimal> GetPriceAsync();
    }

Code:
namespace WalletServices
{
    public class BitfinexService : ApiCall, IPriceClient
    {
        public async Task<decimal> GetPriceAsync()
        {
            JObject jResult = await GetApiResponse("https://api.bitfinex.com/v1/pubticker/btcusd");
            decimal price = (decimal)jResult["last_price"];

            return price;
        }
    }
}


Title: Re: [C#][Github] Watch Only Bitcoin Wallet. Keep track of balance and price.
Post by: Coding Enthusiast on November 05, 2016, 12:10:46 PM
@doof Thanks a lot for your feedback.

If  you have an enum, use it instead of a string in the get method.  Thats what its for.

I am still new to C♯ and definitely to MVVM and the reason why I did that was because I got an error in my view (MainWindow) xaml file which was unable to resolved the dependency! This and some other bugs/problems are the reason why I have not yet merged that branch.

But I like the follow up about open/closed principle after reading more about it.
So should it be like this:
In ViewModel:
Code:
....
if(//bitfinex is selected)
   IPriceClient MyClient = new BitfinexService();
else if (//some other one is selected)
   IPriceClient MyClient = new SomeOtherService();
.....
price = Myclient.GetPriceAsync();
In Services:
Code:
public class BitfinexService : ...
...
public class SomeOtherService : ...


Title: Re: [C#][Github] Watch Only Bitcoin Wallet. Keep track of balance and price.
Post by: Coding Enthusiast on November 16, 2016, 06:10:07 PM
Version 2.0.0 is complete, and will be merged as soon as I find some time to test it (It has been a busy month).

https://github.com/Coding-Enthusiast/Watch-Only-Bitcoin-Wallet/tree/MVVM
https://i.imgur.com/y7dGPRf.jpg (https://i.imgur.com/y7dGPRf.jpg)
*click to view full size*

Included in this version:
  • Code is following the MVVM pattern!
  • Every bitcoin address is checked to make sure it is a valid base58 address
  • GUI changed to GridView to make Add/Edit/Remove Function easier
  • MainWindow now has hotkeys for Saving (Ctrl+S), Opening Settings (F2), Opening Help (F1)
  • Added a new option in SettingsWindow to get bitcoin price from 2 different exchanges (bitfinex and btc-e)

As always feel free to leave any suggestion, feedback, request,... here or on GitHub.


Title: Re: [C#][Github] Watch Only Bitcoin Wallet. Keep track of balance and price.
Post by: RGBKey on November 16, 2016, 11:08:15 PM
This is a nice project, I can respect your enthusiasm for coding. Remember that the more often you do it, the faster you'll get better.


Title: Re: [C#][Github] Watch Only Bitcoin Wallet. Keep track of balance and price(V2.0)
Post by: Coding Enthusiast on December 05, 2016, 05:27:57 AM
Fixed a bug with Price services and released version 2.0.0 by merging the MVVM branch.


Title: Re: [C#][Github] Watch Only Bitcoin Wallet. Keep track of balance and price(V2.0)
Post by: Coding Enthusiast on February 03, 2017, 12:23:58 PM
Released a new version (2.1.0) with so many code improvement, mostly removed the extra assemblies and now only have two main assemblies.
Also improved the SettingsWindow and its interaction.


Title: Re: [C#][Github] Watch Only Bitcoin Wallet. Keep track of balance and price(V2.2)
Post by: Coding Enthusiast on June 25, 2017, 08:16:33 AM
Released version 2.2.0
  • A lot of small code improvements
  • Exceptions are handled and a couple of bugs fixed
  • The Error MessageBox is now hidden and will only appear if there is an error
  • Added a new StatusBar at the bottom of the window
  • Added a new API service for fetching balances (blockr.io)
  • The balance now has a ToolTip showing the difference each time balance is updated
  • Important: Wallet file is not stored in JSON format which makes this new version backward incompatible. This new format reduces the wallet file size a lot and is easier to use.
  • Saving is now completely automatic!


Title: Re: [C#][Github] Watch Only Bitcoin Wallet. Keep track of balance and price(V2.2)
Post by: Coding Enthusiast on December 12, 2017, 06:16:55 PM
Released a small version 2.2.1 (2017-12-9)
  • Replaced blockr API with blockexplorer

Released version 2.3.0
  • Added color codes to balance column (green: increased balance, red: decreased!)


Title: Re: [C#] Watch Only Bitcoin Wallet. Keep track of balance and price(V2.3)
Post by: Coding Enthusiast on January 05, 2018, 06:56:44 AM
Released version 2.4.0
  • Added a new property called TransactionList and a new window for updating it and showing the balance on a given block height. This is useful for checking how much you owned when a forks like Bitcoin Cash, Bitcoin Gold,... happened.


Title: Re: [C#] Watch Only Bitcoin Wallet. Keep track of balance and price(V2.4)
Post by: webling on January 05, 2018, 04:17:24 PM
Good job! Keep it up! Thank you for building a tool for the convenience of others :)


Title: Re: [C#] Watch Only Bitcoin Wallet. Keep track of balance, forks and price(V2.4)
Post by: boludotron on January 10, 2018, 05:03:20 AM
Excellent project for learning.

On a side note; I have been using this web based tool to keep track of my paper wallets across multiple forks. No private keys and looks perfect on my phone. It also links out to the chain's corresponding explorer for further balance verification.

WalletChecker.com


Title: Re: [C#] Watch Only Bitcoin Wallet. Keep track of balance, forks and price(V2.4)
Post by: cryptocropty on January 11, 2018, 03:39:27 PM
I don't want to enter the thread, but WalletChecker is missing https - therefore I would not use it. Should by easy to fix by them.
Excellent project for learning.

On a side note; I have been using this web based tool to keep track of my paper wallets across multiple forks. No private keys and looks perfect on my phone. It also links out to the chain's corresponding explorer for further balance verification.

WalletChecker.com


Title: Re: [C#] Watch Only Bitcoin Wallet. Keep track of balance, forks and price(V2.4)
Post by: Coding Enthusiast on January 11, 2018, 05:08:14 PM
I have a plan to either
- add multiple wallet support, for example you can switch between your bitcoin, bitcoin cash, litecoin,... wallet each a different file with different addresses.
- or make this like a portfolio kind of thing, add something like "addressType" variable and keep everything inside one file
Then check balances from different block explorers for different chains.

Name of the project (Watch Only Bitcoin Wallet doesn't exactly go with this addition, but I think it may be a useful addition.


Title: Re: [C#] Watch Only Bitcoin Wallet. Keep track of balance, forks and price(V2.4)
Post by: Emerger on January 24, 2018, 01:06:50 PM
Cool project! It's encouraged me to install Visual Studio to try it, and follow the progress.

When checking the balance of addresses, both in fork balances and main page,  I am receiving the error "Value was either too large or too small for an Int32." Any suggestions to fix this?

Also, is there any way to import bulk addresses (if not through gui then by editing a file)?

Thanks


Title: Re: [C#] Watch Only Bitcoin Wallet. Keep track of balance, forks and price(V2.4)
Post by: Coding Enthusiast on January 25, 2018, 05:46:05 AM
When checking the balance of addresses, both in fork balances and main page,  I am receiving the error "Value was either too large or too small for an Int32." Any suggestions to fix this?
Thanks for the bug report. This commit should fix it:
https://github.com/Coding-Enthusiast/Watch-Only-Bitcoin-Wallet/commit/263665deb3ce3543fa7ab30ec46329837e25fe5c

Also, is there any way to import bulk addresses (if not through gui then by editing a file)?
Working on it. Will release soon.


Title: Re: [C#] Watch Only Bitcoin Wallet. Suppo SegWit and Forks (V3.0)
Post by: Coding Enthusiast on January 29, 2018, 03:24:12 PM
Released version 3.0.0
  • Added a new block explorer (the only API that supports Bech32 address format) called Blockonomics.
  • The wallet now supports Bech32 SegWit address format, uses Blockonomics api for their balances explicitly.
  • Wallet also has verification capabilities for Bech32 format.
  • Also moved verification classes (Base58 and Bech32) to a new assembly and added some unit tests.


Title: Re: [C#] Watch Only Bitcoin Wallet. Suppo SegWit and Forks (V3.0)
Post by: Emerger on February 12, 2018, 03:14:41 AM
Released version 3.0.0
  • Added a new block explorer (the only API that supports Bech32 address format) called Blockonomics.
  • The wallet now supports Bech32 SegWit address format, uses Blockonomics api for their balances explicitly.
  • Wallet also has verification capabilities for Bech32 format.
  • Also moved verification classes (Base58 and Bech32) to a new assembly and added some unit tests.
Where is it "released"? I do not see 3.0.0 at https://github.com/Coding-Enthusiast/Watch-Only-Bitcoin-Wallet/releases (I guess I should just download latest source)

Thanks for the help on my previous Q's - I'm looking forward to the bulk import option!


Title: Re: [C#] Watch Only Bitcoin Wallet. Support SegWit and Forks (V3.0)
Post by: Coding Enthusiast on February 16, 2018, 10:13:45 AM
Where is it "released"? I do not see 3.0.0 at https://github.com/Coding-Enthusiast/Watch-Only-Bitcoin-Wallet/releases (I guess I should just download latest source)

Releases are basically doing the same thing as "Clone or download" button at this link: https://github.com/Coding-Enthusiast/Watch-Only-Bitcoin-Wallet/archive/master.zip but at different versions (times). so yeah just use "Clone or download" button.
I can add additional files like binaries, but since I am not doing that I didn't see any point in releasing more versions after 1.1.0

Thanks for the help on my previous Q's - I'm looking forward to the bulk import option!

No problem. I've added "bulk import option". Just need to bump the version and update ReadMe file.


Title: Re: [C#] Watch Only Bitcoin Wallet. Support SegWit and Forks (V3.0)
Post by: Coding Enthusiast on February 16, 2018, 10:41:39 AM
Released version 3.1.0
  • Added two ways for importing addresses in bulk: from file and from text. Addresses need to be separated by a new line (1 address per line).

Preview of the "Import From text" window:
https://i.imgur.com/seiinrF.jpg


Title: Re: [C#] Watch Only Bitcoin Wallet. Support SegWit and Forks (V3.0)
Post by: Emerger on February 16, 2018, 12:23:59 PM
Thanks for your reply!

The new import worked for me, although I have only imported one address :)

Just to let you know, when I go to the "Fork Balance Window" and click on "Update Txs" I get a crash: System.OverflowException: 'Value was either too large or too small for an Int32.'

(This seems to happen regardless of whether a specific fork has been chosen from the drop-down or a custom block height has been entered.)


Title: Re: [C#] Watch Only Bitcoin Wallet. Support SegWit and Forks (V3.0)
Post by: Coding Enthusiast on February 16, 2018, 04:17:05 PM
Thanks again for the bug report. This commit should fix it:
68e04c9e17ec48b6e0a3634da274086c094c68b6 (https://github.com/Coding-Enthusiast/Watch-Only-Bitcoin-Wallet/commit/68e04c9e17ec48b6e0a3634da274086c094c68b6)


Title: Re: [C#] Watch Only Bitcoin Wallet. Support SegWit and Forks (V3.0)
Post by: Emerger on February 17, 2018, 04:25:37 AM
Thanks again for the bug report. This commit should fix it:
68e04c9e17ec48b6e0a3634da274086c094c68b6 (https://github.com/Coding-Enthusiast/Watch-Only-Bitcoin-Wallet/commit/68e04c9e17ec48b6e0a3634da274086c094c68b6)

Thank you, that works better now.

If we want to delete all addresses and start over, is there a database file to delete? Perhaps this could be added to the info or the option to start over could be added to the dropdown menu.

Thanks again.


Title: Re: [C#] Watch Only Bitcoin Wallet. Support SegWit and Forks (V3.1)
Post by: Coding Enthusiast on February 17, 2018, 04:34:45 AM
The list of address is simply a GridView. You can select address(es) and simply press Delete on your keyboard to remove them. Press Ctrl+A to select all of them and press Delete on your keyboard.

By the way the wallet file is stored in your "My Documents" path inside a folder called "C.E. Watch Only Bitcoin Wallet":
https://github.com/Coding-Enthusiast/Watch-Only-Bitcoin-Wallet/blob/master/WatchOnlyBitcoinWallet/Services/DataManager.cs#L12


Title: Re: [C#] Watch Only Bitcoin Wallet. Support SegWit and Forks (V3.1)
Post by: Armchair Miner on March 12, 2018, 11:00:12 PM
Questions:
Speaking of forks, does the software support Bitcoin Cash? Bitcoin Gold? Etc?
Can it be used on Linux, such as Debian/Ubuntu?

Thanks.


Title: Re: [C#] Watch Only Bitcoin Wallet. Support SegWit and Forks (V3.1)
Post by: Coding Enthusiast on March 13, 2018, 04:36:48 AM
Speaking of forks, does the software support Bitcoin Cash? Bitcoin Gold? Etc?
The way the forks balance goes is that you can check your balance on a specific block height. So everything is based on bitcoin blockchain not each of these forks' blockchains and it can support anything.
In other words the software can get your transactions and the block height each of these transactions were included in and based on that tells you how much of these fork coins you have.

If you just wanted to see how much balance you have on different chains just use a website like this one: http://www.findmycoins.ninja/

Can it be used on Linux, such as Debian/Ubuntu?
Unfortunately no.


Title: Re: [C#] Watch Only Bitcoin Wallet. Support SegWit and Forks (V3.1)
Post by: pereira4 on July 27, 2019, 08:12:19 PM
My suggestion is to add a column that has a value of "value at time of transaction", this would be extremely useful for, for instance, dealing with taxes when you have a ton of transactions. The value could be fetched from blockchain.info for instance, im not sure about their API but I have been using that site to manually check the value of BTC in fiat at the time a particular transaction happened. I don't know any software or website that does this so manually put it inside an .csv which is annoying. Would be cool if you could dump an export .csv from Core's client into your software and get this column neatly displayed.


Title: Re: [C#] Watch Only Bitcoin Wallet. Support SegWit and Forks (V3.1)
Post by: Coding Enthusiast on July 29, 2019, 06:12:10 AM
My suggestion is to add a column that has a value of "value at time of transaction", this would be extremely useful for, for instance, dealing with taxes when you have a ton of transactions. The value could be fetched from blockchain.info for instance, im not sure about their API but I have been using that site to manually check the value of BTC in fiat at the time a particular transaction happened. I don't know any software or website that does this so manually put it inside an .csv which is annoying. Would be cool if you could dump an export .csv from Core's client into your software and get this column neatly displayed.

I've added "price history" feature that will add a new field to each transaction (https://github.com/Coding-Enthusiast/Watch-Only-Bitcoin-Wallet/blob/f53eedcbd3e38896d2465dd253bf82b243f7dc6e/WatchOnlyBitcoinWallet/Models/Transaction.cs#L23-L31) based on its confirmation time that includes the USD value of that transaction at that time. It will use CoinDesk API since it is more common as an average price source.

The problem is that I'm not sure how to display this feature. For now you can only update this through the ForkBalance window and there is no displaying option but you could use your wallet.json file to analyze if you wanted. I'll probably do some major changes in this app as soon as I get some more free time, making things more automated and update everything in one place and skip repetition (since some parts are updated multiple times even if you already have the history).
Do you have any suggestions for displaying it? I was thinking a line chart showing the history.

As for bitcoin-core compatibility I have it in my TODO list but it is at the bottom of it.


Title: Re: [C#] Watch Only Bitcoin Wallet. Support SegWit and Forks (V3.1)
Post by: pereira4 on July 30, 2019, 03:38:16 PM
My suggestion is to add a column that has a value of "value at time of transaction", this would be extremely useful for, for instance, dealing with taxes when you have a ton of transactions. The value could be fetched from blockchain.info for instance, im not sure about their API but I have been using that site to manually check the value of BTC in fiat at the time a particular transaction happened. I don't know any software or website that does this so manually put it inside an .csv which is annoying. Would be cool if you could dump an export .csv from Core's client into your software and get this column neatly displayed.

I've added "price history" feature that will add a new field to each transaction (https://github.com/Coding-Enthusiast/Watch-Only-Bitcoin-Wallet/blob/f53eedcbd3e38896d2465dd253bf82b243f7dc6e/WatchOnlyBitcoinWallet/Models/Transaction.cs#L23-L31) based on its confirmation time that includes the USD value of that transaction at that time. It will use CoinDesk API since it is more common as an average price source.

The problem is that I'm not sure how to display this feature. For now you can only update this through the ForkBalance window and there is no displaying option but you could use your wallet.json file to analyze if you wanted. I'll probably do some major changes in this app as soon as I get some more free time, making things more automated and update everything in one place and skip repetition (since some parts are updated multiple times even if you already have the history).
Do you have any suggestions for displaying it? I was thinking a line chart showing the history.

As for bitcoin-core compatibility I have it in my TODO list but it is at the bottom of it.


Unfortunately im not familiar with the CoinDesk API. Im really looking forward to "fiat price at the time" information. A graph per each tx would be nice, but maybe a bit overkill for now. Just a simple column next to the txid that shows the value at the time of said tx would be incredibly useful for, like I said, filling taxes.

I would make txid's clickable and an explorer of choice would be opened because sometimes you want to check something and you like the layout of a certain explorer but this just comes to personal preference in how to design the program.

If importing the csv is not near, then it may be a bit of a PITA for those that have tons of transactions, one would need to import each tx one by one and in chronological order but I guess it's better than nothing for now, since all I have right now is manually checking each tx on an explorer id which is hell (btw im talking about having the entire tx history imported in your program with all the data, not just current watch only addresses with funds, so you would have a window for watch only current funds and another window where you can import your entire wallet.dat tx history so you can check those things without having to fire the resource consuming full client in your airgapped computer or wherever you store tx history)


Title: Re: [C#] Watch Only Bitcoin Wallet. Support SegWit and Forks (V3.1)
Post by: Coding Enthusiast on April 13, 2020, 01:51:44 PM
Tiny version update (V. 3.2.1). Fixed some bugs with the APIs and removed the dead ones. Now we have only two and both support Bech32 addresses.

PS. I may continue back-porting features to this project but my focus is going to be on my new project, Denovo, which would eventually be a much more advanced version of this project.


Title: Re: [C#] Watch Only Bitcoin Wallet. Support SegWit and Forks (V3.2.1)
Post by: PrivatePerson on May 06, 2020, 03:33:39 PM
Could you post the compiled exe?


Title: Re: [C#] Watch Only Bitcoin Wallet. Support SegWit and Forks (V3.2.1)
Post by: Coding Enthusiast on May 07, 2020, 04:34:11 AM
Could you post the compiled exe?
https://github.com/Coding-Enthusiast/Watch-Only-Bitcoin-Wallet/releases/tag/V3.2.1