Re: Create variables from the script ?
Re: Create variables from the script ?
- Subject: Re: Create variables from the script ?
- From: Paul Berkowitz <email@hidden>
- Date: Tue, 26 Nov 2002 13:16:20 -0800
On 11/26/02 12:54 PM, "Thomas" <email@hidden> wrote:
>
I was wondering if this would be possible to create variables from
>
within the script. Here is a simple example :
>
>
set list_folder to list folder "a folder"
>
repeat with i from 1 to count of list_folder
>
set vari to item i of list_folder
>
end
>
>
So i would get the name of the first folder in the variable var1, the
>
name of the second folder in the variable var2... and the name of the
>
nth folder in the variable varn.
>
This is impossible right ?
Yes. The way you have it, you'll just be continually resetting your variable
vari to a new value without doing anything with it, except replacing it with
the next value. Instead of that, you could just set a variable to 'item i of
list_folder ' whenever you need to use a variable.
--
Paul Berkowitz
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.