Script references to moving files?

Mark Schonewille m.schonewille at economy-x-talk.com
Sun May 4 18:02:33 EDT 2008


David,

What kind of files are you thinking of? I can think of two kinds:

1) documents: there is no need to remember where these are stored,  
because they are opened by double-clicking them or from within the  
programme and if they move while they are open in the programme, you  
just restore them the first next time they are saved by the programme;

2) components: if they are missing, simply show an error message  
telling the user to re-install the software.

If a file is not either (1) or (2), then make it so by importing it.  
You can store an external file as part of a document or you can turn a  
file into a component and save it in a dedicated folder inside the  
documents/pictures/movies/etc foldet.

Don't make things too complex. You might lose yourself completely in  
this kind of stuff because you can never tell what a user is going to  
do.

Best regards,

Mark Schonewille

--

Economy-x-Talk Consulting and Software Engineering
http://economy-x-talk.com
http://www.salery.biz

Our servers may be off-line between 28 April and 1 May. If you have an  
urgent request, you can contact us at <economy.x.talk at gmail.com>.  
Apologies for any inconveniences.





On 4 mei 2008, at 23:29, David Bovill wrote:

> Strange question - not sure how to express it otherwise. It's a common
> enough thing to need though. Your scripts want a reference to an  
> external
> file, but the user may have moved it in the file system - so you  
> have to
> relink the file / update your data....
>
> Now this is what an alias / shortcut does - or at least certain  
> types of
> alias / shortcut. So its possible I guess.
>
> Now how can Rev scripts do this? My first thought is to create a  
> alias of
> the files, put them into a folder somewhere and associate these  
> aliases with
> the metadata. Your script knows where the alias is (its fixed) and  
> can at
> least on Macs figure out (using AppleScript) where the file is....  
> should
> work a lot of the time (not if file is copied) - no? How about on  
> Windows?




More information about the use-livecode mailing list