Export sketch (using G4P) successful, but app run fails

Hey There,

I did searched for any similar problems on the forum but unlucky to find anything that could help me further.

I’ve created a sketch, using G4P, exported the file successfully
( Processing feedback window :
Compiling resources
Linking
Successfully created C:.…\windows-amd64\UT_Machine_Control.exe
)

and tried to run the “.exe”. When double clicking the “.exe” nothing happens. On some machines I see the processing startup splash screen in a flash, other machines just a windows loading animation for a split second and then nothing.
No processes visible running in task manager.

Some info:
W11 Machine:
Processing 4.0b8
G4P tool 4.4.2.

W10 Machine:
Processing 4.3
G4P Tool 4.4.2

I’ve create a small sketch (not using G4P) to test the machines and on both W10 & W11 they work. The export is created on the W10 machine with administrator rights including the JAVA dir.

If somebody has any idea’s or pointers, greatly appreciated.
what information do you need to be able to give some advise?

Tried to make a basic sketch with G4P (no contrils) and can make and run the exe.

1 Like

To avoid confusion with the G4P library this tool is called G4P GUI Builder or more simply GUI Builder. I will use the latter.

GUI Builder is only used during sketch creation so is completely ignored when the sketch is executed. GUI Builder also creates a second tab called gui.pde which is exported with the application :+1:. It also creates a folder called `GUI_BUILDER_DATA which is also exported but will not be accessed by the app.

Now I have an iMac desktop and W10 laptop so I can’t reproduce your tests but I created a Processing sketch using GUI Builder that had a G4P button and G4P label. On each machine I was able to export the sketch and run the application. Processing on Windows does not support exporting for mac but I did create a Windows export on my iMac but it failed due to a JNI error.

Sorry this doesn’t help much but it seems to me that the problem is not related to GUI Builder or G4P.

1 Like

Hi quark,

Thanks for replying. I think you’re absolutely right. I’m not blaming the awesome G4P builder tool what so ever. Been using it extensively with joy and result. Just trying to trace my errors.
It’s probably my programming skills that somehow mess up the program when exported. The sketch works perfect while running in the processing environment. Just was hoping that someone experience the same challenge.
Is there a way of tracing the fault? Yes I could gradually build the program from scratch and see where I mess up. But that’s quite a labor and time expensive undertaking.

I’ll think about it and probably will comeback on this issue. :slight_smile:

Cheers

I didn’t think that you were. My response wasn’t meant to appear defensive as I am more than happy to accept responsibility for bugs in my code :smile: I was just trying to rule out the possibility so you could focus on more likely areas,

It seems to me that the issue is related to the Java VM since you get a window but it shuts down immediately.

You might check the versions of Java (JRE not JDK) installed on the machines. I suspect there must be some Windows error log files but I am not knowledgeable in this area. Hope someone else can offer more informed advoce.

1 Like

Hi quark,

I think I’ve found the problem. Hopefully you can point me in the right direction. I hope you can remember that I’ve created a new class called: “GEncoderKnob”. If I comment out all related code the export works fine. Like I said in my earlier comments : “It’s probably my programming skills that somehow mess up the program when exported”. This might be the case here :frowning:

A small test program I’ve created, of which the code I’ve shared (in a different post) works under processing IDE but I can’t get it working in an export. Is there a way you can try if you can export the test code and see if you encounter the same issues I’m having?

Any help as usual greatly appreciated.

this [post : G4P Create new Control-class to use in Sketch

I have been doing some experiments and although the export application works with G4P it does not work with your GEncoderKnob class which extends the GKnob class in G4P.

I believe that I understand what is happening but any potential solution requires source code changes in the G4P library code and therefore a new release.

I say ‘potential’ because I need to do some more testing. Also although I suspect the changes needed are very simple I will not be rushing out a new version because there are other issues waiting to be resolved for the next release.

I will keep you posted. :smile:

1 Like

Thanks quark,

No rush. Like I said any help is appreciated.

Cheers