Re: increment a variable
Re: increment a variable
- Subject: Re: increment a variable
- From: RJay Hansen <email@hidden>
- Date: Fri, 04 Mar 2016 08:55:06 -0600
Thanks to all who replied. Brian, I was aware of addressing with their application id and the reasons for doing that, but thanks for the heads up. I think David and Ed’s suggestions which are along the same lines are the solution I need. I was working on something like that but having trouble figuring out how to implement it. Really appreciate the help and suggestions.
RJay
> On Mar 3, 2016, at 5:10 PM, Stockly, Ed <email@hidden> wrote:
>
>
>> As I don’t know how many frames will need to be placed, the repeat loop
>> takes care of placing the correct number but I’m stumped on how to assign
>> the variables to them. Quite possible I’m being dense and missing
>> something obvious, but I can’t figure out how to do this.
>
> Rjay, you're not being dense or missing anything obvious. AppleScript can
> be dense at times and miss obvious things.
>
> I've had a similar issue, and my solution was when I got the number from
> the user, I immediately used a repeat loop to build a list:
>
> Set myTextFrames to {}
> Repeat userProvidedNumber times
> Set the end of myTextFrames to ""
> End repeat
>
> ———
> myTextFrames —>> {"","","","",""}
>
> Repeat with x from 1 to userProvidedNumber
> Set item x of myTextFrames to textFrame x
> End repeat
> ----
> So instead of
>
> variableNameX
>
> you have
>
> item x of myTextFrames
>
> Does that make sense?
>
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden