Yety Another Trouble Running a Project

I just realize that the current project does not works the second time I click in Process: the generated html file is not saved.

More info:
When I realized what happened, I quit Xojo and r-un it again, then, I copy/paste the html data from the DesktopTextArea onto TextEdit and save from there.

Until some minutes ago, I quit the application (not the IDE) and run it again.

Then, I added a New window MenuItem in the FileMenu (not relevant previously) as a test to narrow what happened.

That’s it, but now I do not know from where to search what happened or … I do not know in what Method, Function to search.

The last idea I had was to reset the properties before starting to process the data (add code to do that at the start of the Process code).

Your opinion ?

In the mean time, I will add a Break just before the file creation and see what happens.

I think I found where the error lies (in the saved FolderItem name: concatenation where none is expected…).

Sometimes asking a question leads to undertand the problem.

It is called Rubber Duck debugging. Explaining to someone else the problem often allows you to see the issue for yourself. Even if that person is a rubber duck.

1 Like

Part of the first idea (Reset the Properties) was the solution.

In constructing the Save FolderItem, I used a Property and add a file nameat each run…

So, I add a local variable and use that to store the file name and the suffix (including the file extension:" (i).html”.

This avoid the concanetation that was the troubleshooting:
my_date (1).html
then
my_date (1).html/my_date (1).html

and so on…

Ian: provided the giving explanation is correct and not leading to errors; this is not easy.