GithubHelp home page GithubHelp logo

Comments (23)

coclav avatar coclav commented on May 25, 2024 1

I have been struggling all day long with this issue without success. Once I had fixed the MSVCP100.dll issue, the next one was The application was unable to start correctly (0xc000007b)

image

and I gave up at this stage :(

I went for Resource Hacker which seemed to work so fare

here is my script. Do that before signing and putting it in installer

[FILENAMES]
     Exe=    "c:\path\to\exe\before\yourElectronApp.exe"
     SaveAs= "c:\bla\bla\YourElectronAPpWithCoolIcons.exe"
[COMMANDS]
     -addoverwrite "path\to\icon.ico", ICONGROUP,1,

from electron-packager.

max-mapper avatar max-mapper commented on May 25, 2024

cc @sindresorhus

On Monday, June 1, 2015, iamdriz [email protected] wrote:

I have the following options for my grunt task:

windowsBuild: {
options: {
name: 'Cameron',
dir: 'app',
out: 'dist',
version: '0.25.3',
platform: 'win32',
arch: 'ia32',
icon: 'icon.ico'
}
}

but the icon isn't applied to the final dist app... I just get the default
Electron icon. The ico file is valid at at the specified location!

Tried on Windows 7.


Reply to this email directly or view it on GitHub
#53.

Sent from my phone

from electron-packager.

Flet avatar Flet commented on May 25, 2024

Just for verification, rcedit.exe is available and in the path?
https://github.com/maxogden/electron-packager#building-windows-apps-from-non-windows-platforms

from electron-packager.

iamdriz avatar iamdriz commented on May 25, 2024

But I'm on a windows platform... That article says for building windows apps on non windows platforms.

Sent from my iPhone

On 1 Jun 2015, at 22:04, Dan Flettre [email protected] wrote:

Just for verification, rcedit.exe is available and in the path?
https://github.com/maxogden/electron-packager#building-windows-apps-from-non-windows-platforms


Reply to this email directly or view it on GitHub.

from electron-packager.

max-mapper avatar max-mapper commented on May 25, 2024

@iamdriz you need it on any platform. I assumed it came with windows but I am probably mistaken (I don't test on windows, I rely on windows to fix issues like that). Can you see if you have rcedit.exe on your machine? If not, we'll have to add instructions on how to install it on windows to the readme

from electron-packager.

junosuarez avatar junosuarez commented on May 25, 2024

@maxogden rcedit.exe is a tool made by the electron team for editing Windows executables... it does not come with Windows. We should update the readme!

from electron-packager.

sindresorhus avatar sindresorhus commented on May 25, 2024

But it does come with the node module rcedit that electron-packager depend on https://github.com/atom/node-rcedit/blob/master/bin/rcedit.exe

We should make sure everything is correct here: https://github.com/maxogden/electron-packager/blob/ac8aea014e04fa65a234f7398aca864f0524fecc/win32.js#L109 But I have a strong feeling it's something with rcedit.

from electron-packager.

max-mapper avatar max-mapper commented on May 25, 2024

ah ok I figured it was some sort of minimal polyfill for non windows sytems

On Mon, Jun 1, 2015 at 3:14 PM, jden [email protected] wrote:

@maxogden https://github.com/maxogden rcedit.exe is a tool made by the
electron team for editing Windows executables... it does not come with
Windows. We should update the readme!


Reply to this email directly or view it on GitHub
#53 (comment)
.

from electron-packager.

iamdriz avatar iamdriz commented on May 25, 2024

Where should rcedit.exe live in relation to the Gruntfile.js? I've tried it at the same level but doesn't seem to have fixed the issue with the icon.

from electron-packager.

junosuarez avatar junosuarez commented on May 25, 2024

@iamdriz when you npm install electron-packager, you should have (relative to the package path) node_modules/rcedit/bin/rcedit.exe

from electron-packager.

iamdriz avatar iamdriz commented on May 25, 2024

And where does this come from? And by relative you mean it's a node module inside the electron-packager folder.

Sent from my iPhone

On 2 Jun 2015, at 17:31, jden [email protected] wrote:

@iamdriz when you npm install electron-packager, you should have (relative to the package path) node_modules/rcedit/bin/rcedit.exe


Reply to this email directly or view it on GitHub.

from electron-packager.

junosuarez avatar junosuarez commented on May 25, 2024

Yes, it is distributed in the rcedit npm package

from electron-packager.

iamdriz avatar iamdriz commented on May 25, 2024

Okay I installed rcedit next to electron-packager but the icon is only viewable in the Windows Explorer preview bar and not on the window itself, the taskbar, or the actual file. Manually running rcedit and grunt-rcedit solves this and correctly applies the icon. So it seems that the packager isn't running rcedit properly nor does it use the other built-in features as changing copyright info etc.

from electron-packager.

mhkeller avatar mhkeller commented on May 25, 2024

I'm also running into an issue of the icon not being set but I'm on os x. Here's the command I'm running:

electron-packager ./ NewsLynx --platform=darwin --arch=x64 --version=0.28.1 --icon=merlynne.ico --prune

When it builds, it seems to flash to the default Electron icon from another state. This could be the custom icon or the default "Paper and pencils" os x icon.

Are there any file size / type / dimension restrictions to be aware of? I've tried it with png, ico and icns.

from electron-packager.

malept avatar malept commented on May 25, 2024

@mhkeller I think your problem is different, this is Windows-specific. The OSX app requires an icns file.

from electron-packager.

IronGeek avatar IronGeek commented on May 25, 2024

Hi,
Just trying to share my experience here as I just had the same issue today with a fresh Windows 8.1 64-bit installation.

The electron-packager does not throw any error, everything seems fine, yet the icon is not applied to final output. But when I try to run the rcedit directly... well, That's when I was greeted with this error message:

2015-07-07_19-09-46

It seems rcedit require VC++ 2010 redistributable components to run, Visual C++ 2010 Redistributable Package (x86) to be exact. I installed the x64 version first and learn it the hard way... 😫

from electron-packager.

kethinov avatar kethinov commented on May 25, 2024

👍 thanks @IronGeek I was seeing the same error when manually running rcedit.exe as well, however even after installing the VC++ dependency, rcedit still does not correctly apply the icon to my app.

When I run the same command to build my app for Windows from an OS X dev environment, rcedit runs correctly, so there is obviously still something screwy going on on my Windows dev env... 😕

from electron-packager.

wearhere avatar wearhere commented on May 25, 2024

Some details about my failing environment and I how I fixed it, largely confirming @IronGeek's and @kethinov's posts:

  • I'm running electron-packager in Windows 8. Here, I was seeing electron-packager silently fail to edit the icon
    • though I was seeing rcedit errors when trying to run grunt-electron-installer.
  • When running electron-packager in OS X 10.10.5 (with Wine), it succeeded in editing the icon.
  • When I installed the VC++ 2010 components linked by @IronGeek, then electron-packager succeeded in editing the icon in Windows 8.
  • My coworker was able to successfully edit the icon without installing anything in Windows 10.

So, perhaps this is just fixed by updating to the latest VC++ toolchain? Though I know that didn't quite work for @kethinov.

from electron-packager.

dhildebrandt avatar dhildebrandt commented on May 25, 2024

I am very grateful for this thread, which walked me all the way through up to getting the application having our customized icon. For reference:

  • Running Windows 10
  • Added RCEDIT into the path
  • installed VC+2010 components

Now I'm working on why the desktop shortcut that points to the correctly iconified application is still itself Electron's icon. If I figure it out I'll report back to this thread.

from electron-packager.

dhildebrandt avatar dhildebrandt commented on May 25, 2024

In the Properties of the shortcut, one can select the icon from among those in the exe. n.b. this is the Windows dialog. I changed it to the one my app presented (the customized one). I changed no code. In future runs of rebuilds of the installer, the shortcut was installed with the correct customized icon. Registry madness?

from electron-packager.

malept avatar malept commented on May 25, 2024

It's been a while since I've dealt with Windows, but I thought desktop shortcuts defaulted to the icon of the .exe. It shouldn't affect other desktop shortcuts or especially the original executable's icon. Perhaps some weird icon caching was happening?

from electron-packager.

dhildebrandt avatar dhildebrandt commented on May 25, 2024

I have an earlier snapshot of the VM I am using; perhaps I can fork the VM from there and see if I can replicate the issue.

from electron-packager.

junosuarez avatar junosuarez commented on May 25, 2024

Windows shortcut icons default to the default app icon, but they can also be set to any icon resource, e.g., another icon resource embedded in the target executable or an icon resource in a dll. I know there are ways to change this programmatically, a super quick search brings up https://blogs.technet.microsoft.com/heyscriptingguy/2005/08/12/how-can-i-change-the-icon-for-an-existing-shortcut/ - hope this helps point in the right direction!

from electron-packager.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.