Page 1 of 1

loading a gcode file from a button press

PostPosted: Tue May 30, 2023 4:37 pm
by frez1001
Hello,

How would I go about loading a gcode file from a button press?

we have have a few files that need quickly changed on the fly. so having a few buttons to press to load the file would be very helpful. The names of the file can be anything and dont change.

Thank you!

Re: loading a gcode file from a button press

PostPosted: Tue May 30, 2023 7:21 pm
by odino87
I have used the following code inside the button click event
Code: Select all
UC.Loadfile(Path.GetFullPath(filePath));

as you can see i use the absolute path of the file I want to load :)

Hopes it can help you