Trouble with script

Charles Szasz cszasz at mac.com
Sun Mar 25 12:03:51 EDT 2007


I have a project that requires one screen or one card to be exported  
as a RTF file. Since this is not possible at this time in Rev, I  
created a template in the Pages word processor of the card that I  
want to export and saved it as Template.rtf.  Then I use symbols such  
as a 1#, 2#, 3#,. etc.,  in the template for each occurrence of a  
score that will be inserted from Rev. I have 81 occurrences of  
scores. The following script does not work for one occurrence. The  
template.RTF file is in the same directory as my Rev stack file and I  
am using Rev 2.7.4 with OS 10.4.8. I added a field "new" to see what  
was going on in the script. Nothing appears in the field "new" when I  
run the handler.

on mouseUp
   put URL "file:template.rtf" into tRTFdata
   replace "#1" with the htmltext of field "vmiFld" in tRTFdata
   put tRTFdata into field "new"
end mouseUp

Any suggestions would be appreciated!

Charles Szasz
cszasz at mac.com






More information about the use-livecode mailing list