Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct
Taking text input, manipulate it, and write to a file using QML and JS
then write the results to an external files, all without involving c++.
The only possible way to do with QML is using local database.
Lorenz last edited by Lorenz
If you want to write to a file from QML, you either have to step into C++ yourself and create some helper code, or you can try out the V-Play SDK and enjoy the fileUtils context property like this:
bool success = fileUtils.writeFile("myFile.txt", "myFileContentString")
Read more on that in our forum.
@p3c0 Thanks. I am trying to use QML / JS to dynamically create some C++ functions, presumably saved in a text file, which is later compiled and executed with the rest of the C++ coding. My understanding is that to achieve this I must not involve C++ in the creation of the dynamic c++ coding. Is that correct? Is there any other way to achieve it?
What exactly are you trying to do ? An IDE with Qt Quick ?
@SGaist I am trying to create two executables, with the first one generating outputs that will be used by the second one. I am trying to set it up such that the the user only need to click a button once and it it will be run the two executables in sequence. Is there a way to do that? If I have to do run it in two steps, I think there must be a way to combine the GUIs for the two into one. Can you let me know how? Thanks!
Creating an executable requires compilation thus my question. You can't just write a c++ and make it part of another application.