ProScan: Activity indicator

ProScan

Software Provider
Premium Subscriber
Joined
Jul 2, 2006
Messages
8,079
Location
Ontario, Calif.
I've been doing some tests and searching too. I've been pinning to the taskbar and unpinning to simulate the problem. I don't have a solution at this time. I believe this is a Windows problem. I don't think I can fix the problem in code. You may be wondering why other apps such as Sentinel when pinned to the taskbar, the icon looks normal and that's because the icon is set at the application level. In ProScan, the default icon is set at the application level but for changing it dynamically when there's scanner activity, the icon needs to be set at the form level and when the form icon changes, the form title/caption area changes and that will make the taskbar icon change too..

I made a test app in c# targeting the .NET 9.0. That way the .NET Framework is out of the picture. Here's a snippet of the code to set the form icon. I think setting the form icon is the only way to change the icon dynamically in the taskbar.

{edit} I was searching for 'api to set the taskbar icons' w/ no relevant results.

C#:
private void button1_Click(object sender, EventArgs e)
{
    activity= !activity;
    if (activity == false)
    {
        this.Icon = normalIcon;
    }
    else
    {
        this.Icon = activityIcon;

        // same result as above which is the taskbar icon will not work after the app has been pinned and unpinned
        // SendMessage(this.Handle, WM_SETICON, ICON_SMALL, activityIcon.Handle);
    }
}
 
Last edited:

eorange

♦RF Enabled Member♦
Joined
Aug 20, 2003
Messages
3,033
Location
Cleveland, OH
I made a test app in c# targeting the .NET 9.0. That way the .NET Framework is out of the picture.
Not suggesting you actually do this because of the hairy implications, but would Win32 give you the API you're looking for?
 

KevinC

Encryption
Super Moderator
Joined
Jan 7, 2001
Messages
13,406
Location
I'm everywhere Focker!
If you have multiple instances you can overcome the issue by creating a .bat like in the post below...

 

kruser

Well Known Member
Premium Subscriber
Joined
Nov 25, 2007
Messages
5,087
Location
W St Louis Cnty, MO
If you have multiple instances you can overcome the issue by creating a .bat like in the post below...

So this issue and the other issue regarding muting/unmuting were both fixed by using a batch file to start all the instances you need?
This is good to know!
 

fxdscon

¯\_(ツ)_/¯
Premium Subscriber
Joined
Jan 15, 2007
Messages
7,515
If you have multiple instances you can overcome the issue by creating a .bat like in the post below...


Some may find it handy to add this line to the .bat file as well: ;)

to use your default browser....
Code:
start "" "https://forums.radioreference.com/whats-new/posts"

to use a specific browser.....
Code:
start "" "C:\Program Files\Mozilla Firefox\firefox.exe" "https://forums.radioreference.com/whats-new/posts"
 

KevinC

Encryption
Super Moderator
Joined
Jan 7, 2001
Messages
13,406
Location
I'm everywhere Focker!
Some may find it handy to add this line to the .bat file as well: ;)

to use your default browser....
Code:
start "" "https://forums.radioreference.com/whats-new/posts"

to use a specific browser.....
Code:
start "" "C:\Program Files\Mozilla Firefox\firefox.exe" "https://forums.radioreference.com/whats-new/posts"
And get creative and make a shortcut to the .bat and make the icon be the ProScan icon.
 

rdxny

Member
Premium Subscriber
Joined
Oct 13, 2015
Messages
112
I see the same on my win11 pc. If I create a new folder, copy Proscan files to it and run proscan.exe, I see a generic square icon with the requested colored box on the taskbar. 2025-05-03_16h57_36.jpg


If I then make a shortcut for Proscan.exe and move to desktop, then run that, I get a different icon (the scanner icon) but no colored box with transmissions. 2025-05-03_16h59_17.jpg
 
Top