Skip to content

Commit

Permalink
Update the code for bscscan & others networks ui update
Browse files Browse the repository at this point in the history
  • Loading branch information
AbdeLhalimSB committed Aug 26, 2023
1 parent 200df05 commit 28d3fce
Show file tree
Hide file tree
Showing 13 changed files with 12 additions and 6 deletions.
Binary file not shown.
Binary file not shown.
Binary file modified .vs/Crypto_Wallets_Scanner/v17/.suo
Binary file not shown.
14 changes: 10 additions & 4 deletions Crypto_Wallets_Scanner/Main.cs
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ public Main()
}

List<string> wallets = new List<string>();

string result = string.Empty;
private void button1_MouseHover(object sender, EventArgs e)
{
start.ForeColor = Color.White;
Expand Down Expand Up @@ -58,7 +58,7 @@ private void Worker_DoWork(object sender, DoWorkEventArgs e)
"https://polygonscan.com/address/",
"https://ftmscan.com/address/",
"https://snowtrace.io/address/",
"https://moonriver.moonscan.io/",
"https://moonriver.moonscan.io/address/",
"https://moonscan.io/address/",
"https://cronoscan.com/address/"
};
Expand Down Expand Up @@ -86,38 +86,44 @@ private void Worker_DoWork(object sender, DoWorkEventArgs e)
if (b == 0)
{
blockch = "BNB";
result = ws.GetWalletBallance(wallet, blockchains[b], blockch, "dropdownMenuBalance");
}
else if (b == 1)
{
blockch = "Ether";
result = ws.GetWalletBallance(wallet, blockchains[b], blockch, "dropdownMenuBalance");
}
else if (b == 2)
{
blockch = "Polygon";
result = ws.GetWalletBallance(wallet, blockchains[b], blockch, "availableBalanceDropdown");
}
else if (b == 3)
{
blockch = "Fantom";
result = ws.GetWalletBallance(wallet, blockchains[b], blockch, "availableBalanceDropdown");
}
else if (b == 4)
{
blockch = "Avalanche";
result = ws.GetWalletBallance(wallet, blockchains[b], blockch, "availableBalanceDropdown");
}
else if (b == 5)
{
blockch = "MoonRiver";
result = ws.GetWalletBallance(wallet, blockchains[b], blockch, "availableBalanceDropdown");
}
else if (b == 6)
{
blockch = "MoonBeam";
result = ws.GetWalletBallance(wallet, blockchains[b], blockch, "availableBalanceDropdown");
}
else
{
blockch = "Cronos";
result = ws.GetWalletBallance(wallet, blockchains[b], blockch, "availableBalanceDropdown");
}

string result = ws.GetWalletBallance(wallet, blockchains[b], blockch);

// Report progress and result to the UI thread
worker.ReportProgress((progress * 100) / totalWallets, result);

Expand Down
4 changes: 2 additions & 2 deletions Crypto_Wallets_Scanner/Wallets_Scanner.cs
Original file line number Diff line number Diff line change
Expand Up @@ -24,13 +24,13 @@ public Wallets_Scanner(string wallet_address)
{
this.wallet_address = wallet_address;
}
public string GetWalletBallance(string wallet,string blockchaine,string blockch)
public string GetWalletBallance(string wallet,string blockchaine,string blockch,string id)
{
string result = "";
HtmlAgilityPack.HtmlWeb web = new HtmlWeb();
HtmlAgilityPack.HtmlDocument doc = web.Load(blockchaine + wallet);
System.Threading.Thread.Sleep(2000);
var bnb = doc.GetElementbyId("availableBalanceDropdown");
var bnb = doc.GetElementbyId(id);
//string tokens = bnb.InnerText.Substring('\n');
if (bnb != null)
{
Expand Down
Binary file modified Crypto_Wallets_Scanner/bin/Debug/Crypto_Wallets_Scanner.exe
Binary file not shown.
Binary file modified Crypto_Wallets_Scanner/bin/Debug/Crypto_Wallets_Scanner.pdb
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file modified Crypto_Wallets_Scanner/obj/Debug/Crypto_Wallets_Scanner.exe
Binary file not shown.
Binary file modified Crypto_Wallets_Scanner/obj/Debug/Crypto_Wallets_Scanner.pdb
Binary file not shown.
Binary file not shown.

0 comments on commit 28d3fce

Please sign in to comment.