|Version 1 (modified by damato, 22 months ago) (diff)|
The "WRITEEDITOR TEXT" arexx command doesn't seem to work?
If you are having trouble getting the WRITEEDITOR TEXT arexx command to work as expected and your script always returns an error similar to that one:
1 *-* WRITEDITOR TEXT Hello World; +++ Command returned 10
then chances are high that you simply missunderstood or missread the documentation about the WRITEEDITOR command in the YAM amigaguide documentation. So please note that using the TEXT attribute of the WRITEEDITOR command implies to take care of a special text quoting as otherwise YAM isn't able to identfy what the attribute and what the actual text is you supplied to the WRITEEDITOR arexx command.
For example, if you want to put the text "Hello World!" into an already opened write window in YAM you are ought to have you arexx script designed like:
/* My script */ ADDRESS YAM; MAILWRITE WINDOW 0; 'WRITEEDITOR "TEXT Hello World!"'
Please take special attention on the used quotating marks (' and ") used on the WRITEEDITOR command. Any other combination of these quotation marks will actually result in the WRITEEDITOR command to return the above mentioned error. However, if you want to just issue the e.g. CLEAR attribute you can also simply use "WRITEEDITOR CLEAR" without any quotating marks. The special quotation is only required for the TEXT attribute.