nwjs 'run file' bug (?)

0 favourites
  • 8 posts
From the Asset Store
Full game Construct 2 and Construct 3 to post on Google Play
  • Problem Description

    The nwjs command 'run file' doesn't do anything.

    Attach a Capx

    https://dl.dropboxusercontent.com/u/705 ... e_bug.capx

    Description of Capx

    Bare-bones capx that tries to execute dxwebsetup.exe from within its build folder on start of layout.

    Steps to Reproduce Bug

      Export the project then run it.

    Observed Result


    Expected Result

    dxwebsetup.exe gets executed on layout start.

    Affected Browsers


    Operating System and Service Pack

    Windows 7 Home Premium Service Pack 1

    Construct 2 Version ID



    I guess I could just be using it wrong, but I don't see how from reading the manual.

  • ErekT

    You haven't set the 'Preview Browser' to NW.js, so how are you expecting this to work?

  • This is something I've been thinking about for a little while now because nw.js will not function nearly well enough unless dxwebsetup.exe has been installed on the player's computer. I assume that you are not just sending a zipped folder of the nw.js files, because then you could just ask them to install dxwebsetup.exe as part of the process for your game; so are you using a program like InnoSetup to create a .exe file of your nw.js game? If so (and this is the area I have no experience of, but is the direction you should search) then you can use some help from stackoverflow which contains the code you need to place in your InnoSetup script before compiling the final .exe - I have not tried this myself yet, but I suspect that this is what you need...?

    Edit - zenox is right, looking at your capx, and there's no example file or path to that example file in the nw object. I'm also not sure about what a player might think if a game just starts trying to run executables on the fly; just a thought.

  • zenox98:

    Oops, forgot to set it for the example capx. Anyways, I meant to say 'export project' in steps to reproduce.


    Ah, doing 'run file' on dxwebsetup.exe was just for testing actually The problem is I can't get the nwjs 'run file' command to run *any* executable files.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • ErekT

    Does this work for you?

  • I completely misunderstood what you were trying to do, lol.

  • I completely misunderstood what you were trying to do, lol.


    Hehe, A for effort brudde


    That worked. But I don't understand why my example doesn't?

    Okay. To clarify, I'm trying to run an executable that changes OS resolution to something lower on game start, then switches back to the original resolution when the game quits, gets suspended, or goes into window mode. Does it have to be an 'on clicked' event maybe?

  • Closing as won't fix: you do not specify a full path, so the OS will try to guess the location of "dxwebsetup.exe". Presumably it guesses wrong and does not run the file. You probably want to include NWjs.AppFolder in the path to make it explicit.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)