XIDE: How to add app icon and use Assembly.prg

This forum is meant for questions and discussions about the X# language and tools
Post Reply
User avatar
SHirsch
Posts: 286
Joined: Tue Jan 30, 2018 8:23 am
Location: Germany

XIDE: How to add app icon and use Assembly.prg

Post by SHirsch »

Hi,

how can I add an icon for my exe file and still have the version info from Assembly.prg in file properties available? (see att.)
I tried Properies -> Application Icon.
Is there another way?

Stefan
Attachments
NoIcon.PNG
NoIcon.PNG (17.28 KiB) Viewed 421 times
WithIcon.PNG
WithIcon.PNG (14.77 KiB) Viewed 421 times
User avatar
Chris
Posts: 4906
Joined: Thu Oct 08, 2015 7:48 am
Location: Greece

XIDE: How to add app icon and use Assembly.prg

Post by Chris »

Hi Stefan,

The only way I know to do this, is to manuall provide a native resource which also provides this information.

Please try the attached .rc file, edit it so it contains your information add it to your app/library with Add Existing->Add Native resources (not regular resources, has to be "native"). You should now have both an app icon and also version info.

Chris
Attachments
version.zip
(447 Bytes) Downloaded 65 times
Chris Pyrgas

XSharp Development Team
chris(at)xsharp.eu
User avatar
robert
Posts: 4520
Joined: Fri Aug 21, 2015 10:57 am
Location: Netherlands

XIDE: How to add app icon and use Assembly.prg

Post by robert »

Stefan,
If you app has native resources (rc files, like VO window or menu resources) then you need an native versioninfo to set the version. Otherwise you can add an AssemblyInfo.prg with assembly attributes. The compiler will set the information from these attributes also as version info on the DLL/EXE.
An example from a assemblyinfo.prg is in every new X# project inside Visual Studio.

Robert
XSharp Development Team
The Netherlands
robert@xsharp.eu
User avatar
SHirsch
Posts: 286
Joined: Tue Jan 30, 2018 8:23 am
Location: Germany

XIDE: How to add app icon and use Assembly.prg

Post by SHirsch »

Hi Chris,

I tried in Visual Studio. There I have added an icon resource and set the application icon. The information from AssemblyInfo.prg is still used.
But how can this be done in XIDE? Without using native resources.

Stefan
User avatar
Chris
Posts: 4906
Joined: Thu Oct 08, 2015 7:48 am
Location: Greece

XIDE: How to add app icon and use Assembly.prg

Post by Chris »

Hi Stefan,

Hmm, I don't think this is possible, as Robert said, if you have any other native resources, you need to use the version info in native resources as well. Maybe we are both missing something though, so can you please zip and send me the VS solution where you have this working?

Chris
Chris Pyrgas

XSharp Development Team
chris(at)xsharp.eu
Post Reply