POSIX file "/Volumes/my dmg/some file.txt" Therefore, your entire AppleScript that will open the file (as if the user had double-clicked on it) will be: tell application id "" to open the ¬ The path to this file will be located at: /Volumes/my dmg/some file.txt Let's then say that there's a file called "some file.txt" contained within the disk image that you wish to open. dmg file itself, but it may be the same). dmg file to mount (open) it, the name of the disk that appears on your desktop (or in the sidebar of a Finder window) is "my dmg" (this may be different from the name of the. Let's say that when you double-click your. It sounds like you already know the name of the file you wish to be opened. dmg file (or disk image) is an item on the filesystem, which means it can be manipulated using AppleScript. Try to avoid looking for solutions that involve simulating clicks or keypresses, as these sorts of scripts are really case-specific, liable to break easily and frequently, and prohibit any additional interaction between the user and the computer whilst it is running.Ī. The code snippet you borrowed doesn't relate to what you're trying to achieve, so you can safely throw that away.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |