Etiqueta

20 enero 2016

Como abrir documentos en Mac OS y en Windows, desde Omnis.

Abrir documentos en Mac OS.


Calculate applescript as con('property target_URL : "', lvpath,'"',kCr,'open location target_URL')
Do method $doApplescript (applescript,results) Returns #F


Si lvpath es 'file://pathtofile') --≥ abre un archivo
Si lvpath es 'http://www.myurl.org/path.html' --≥ abre el navegador
Si lvpath es 'mailto:name@email.com'  --≥ abre el cliente e-mail
Si lvpath es 'feed:rssfeed path'  --≥ abre el lector de rss

Abrir documentos en Windows.


Calculate lvPath as 'C:\Users\Tom\Downloads\demo\demo.html'
Register DLL ("SHELL32.DLL","ShellExecuteW","JJCCCCJ")
Call DLL ("SHELL32.DLL","ShellExecuteW",0,"open",lvPath,"","",0) Returns lvHandle



No hay comentarios: