Monday, 7 April 2008

Integrating OSX clients and JBlooming web services

Recently I started to study AppleScript in order to translate a Visual Basic macro for Microsoft Word into AppleScript for Mac Word 2007. The decision to adopt AppleScript was taken because Mac Word doesn't use Visual Basic for macro since from Mac Word 2007. CodeChecker is the macro on which I'm working, it performs text correction using our on line dictionary web service (in the Smallcodes project). The main features of this code checker macro lay in the language where it performs correction, it uses dictionaries of minority languages like Ladin, Occitan, Ghedina. In our CodeChecker script we used SOA technology, that requires a particular library under Windows (SOA webkit 3.0), under Mac osx that library doesn't exist , but it was not a problem, because Applescript has a tool to generate the stub! Myracolous! The first approach with Applescript was quite traumatic because the syntax' logic is completely different from other script languages, it is oriented to a no programmers' audience for sure, in fact most of standard constructs like assignment or declaration is quite out of programming standards. I have to admit that it is a quite powerful scripting language, it allows complete control on system functions, you can also control single applications and use all system libraries, call other scripts made in other languages like Python or Perl and use the result inside the caller Applescript. In first instance Applescript was made to supply some standard system operations like batch operations using automator, but in recent years it was adopted as the scripting language for Microsoft office suite.
Roberto Baldi

No comments: