Using Texteditor with xojo

I’d like to do the following from within a dojo application :

  1. Opening TextEditor via a kind of ‘shell’ in my program.
  2. Reading a record containing RTF-data from a database-table into TextEditor.
  3. Edit the text in TextEditor.
  4. Saving the RTF-data back to the database-table.
    Should this be possible ? And how do I fix this.
    Does somebody has an answer ? Many regards.

It might make more sense to edit the text directly directly into your app rather than starting an external text editor. The TextArea can load and edit simple RTF files. Also, 3rd parties offer alternative text editors with better RTF support.

If you really want to use an external text editor, you could fetch the data from the DB and save it to a file. Then you can open the text editor (using FolderItem.Launch) supplying the file as the parameter. I don’t see how your app would know when the user is done editing, however. And nothing would prevent the user from saving the file elsewhere. Maybe AppleScript could be used for communication?

ShowURL might be of help to you.