Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

ICON ATACHMENT IN FOXPRO

Status
Not open for further replies.

NESTOR19

Programmer
Jan 21, 2021
3
US
Hi everyone . I'd started to have problems when I try to attach an icon to a new exe file . I assume it was a recent update in W10 . Anyone with the same problem ? Did you resolve this problem ? . Thank you all !!
 
I'm wondering if the OP is not seeing the icon for his application appearing on the taskbar under Windows 10, I know when I run VFP apps on Windows servers they often only get a generic windows icon.

I have always assumed it was because windows now expects a higher resolution icon than the 32x32 one I tended to use...

Regards

Griff
Keep [Smile]ing

There are 10 kinds of people in the world, those who understand binary and those who don't.

I'm trying to cut down on the use of shrieks (exclamation marks), I'm told they are !good for you.
 
I've been using an Icon Editor for years just for creating icons with 32bit, 8bit and 4bit bitmaps in 16x16,24x24,32x32,48x48,256x256 pixels ( IN ONE SINGLE ICO FILE!!!). Windows can take want it likes most and usually an icon is shown without problems.

But....

within Windows Explorer this isn't always the case. IF the icon isn't shown correctly with Explorer most of the time this is because of a corrupted thumbs.db file. Sometime later this is corrected automatically by windows itself, but for an ad hoc refresh in most times its enough to change the folder view to 'Details' and then to delete the thumbs.db file.
If the file isn't to be seen, the option to make hidden/system files visible has to be activated.

HTH

-Tom
 
Hi,
The icon,to be shown in your exe you should go MENU -> Project -> Project info -> you will than get a screen where you can publish a lot and also the icon.
ProjectInfo_wqxqg0.png

AttachIcon_wzh6yl.png

Stay healthy,
Koen
 
I lately came across this:


And this might also help:

The main window in VFP apps I think is always _screen, no matter if visible or not, unless you have your own separate top level form. But then also an icon you set for the pjx is not automatically each Windows icon, you have to set that in your base form for every form.


Chriss
 
But then also an icon you set for the pjx is not automatically each Windows icon, you have to set that in your base form for every form.

Chris, that is correct. But just to be clear: if the OP was referring to the EXE's icon, that is, the one you would expect to see in File Explorer or in shortcuts on the desktop, then that's the one that you specify in the Project Info dialogue. The one that you specify in the Icon property of _SCREEN is the one that appears in the title bar of the app's main window, and also on the taskbar.

It's still not clear which icon the OP is referring to - or, for that matter, what the problem is that he is seeing.

Nestor, if you are still around, please come back into this discussion so that you can clarify the above points.

It would also be helpful to know if this is a problem that you are only seeing on your own computer, or one that users are reporting to you.

Mike



__________________________________
Mike Lewis (Edinburgh, Scotland)

Visual FoxPro articles, tips and downloads
 
First, my apologies Mike Lewis is right! The problem I have is: In the project INFO window when I try to attach an icon It will not let me. No message returns. As soon as I choose the ICO FILE the check box turns empty. As Mike mentioned the problem is not related with a form icon or main screen, but with the Icon that is shown in explorer.

Screenshot_2021-01-23_235505_d0nkw5.png


In the old projects as you can see the Icon is there , but in the new ones I can't . I even tried with 16x16 but it was not solution

Thanks again to everybody!
 
Nestor, the behaviour you are seeing is consistent with a faulty ICO file. If you try to attach an ICO that it not a valid icon, the checkbox will clear itself and there will be no error message.

Is this a new ICO file that you are using? If so, what happens if you add an icon from another project that you know works correctly?

Also, check the size of the icon. My understanding is that the ICO file must contain two icons, one at 16 x 16 and one at 32 x 32. I'm not completely sure about that, but it is what I have always done.

Mike

__________________________________
Mike Lewis (Edinburgh, Scotland)

Visual FoxPro articles, tips and downloads
 
Me said:
My understanding is that the ICO file must contain two icons, one at 16 x 16 and one at 32 x 32.

I've just done a quick test. According to what I am seeing, the ICO must contain a 32 x 32 icon. If it does not, the checkbox will clear itself and no icon will appear, and there will be no error message. It doesn't matter what other icons the file contains. The 16 x 16 icon does not appear to be essential.

Mike

__________________________________
Mike Lewis (Edinburgh, Scotland)

Visual FoxPro articles, tips and downloads
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top