Re: Any way to avoid huge property lists at the top of a script?
Re: Any way to avoid huge property lists at the top of a script?
- Subject: Re: Any way to avoid huge property lists at the top of a script?
- From: "S. J. Cunningham" <email@hidden>
- Date: Fri, 16 Oct 2015 18:23:12 -0400
On Oct 16, 2015, at 6:05 PM, Stockly, Ed wrote:
> property allMyProperties : {}
>
> my SetPropValues()
> —the rest of your script
>
> on SetPropValues()
> set allMyProperties to {semSystemStateFolderName:"", semSystemStateFolder:"", semSystemStateSemDisarmedName:"Disarmed", semSystemStateSemBStartingUpName:"Starting Up", semSystemStateSemArmedName:"Armed", semSystemStateSemBAlarmedName:"Alarmed", semSystemStateSemNamesList:{}, semSystemStateSemDisarmedRecord:{S_Name:"", S_Folder:""}, semSystemStateSemStartingUpRecord:{S_Name:"", S_Folder:""}, semSystemStateSemArmedRecord:{S_Name:"", S_Folder:""}, semSystemStateSemAlarmedRecord:{S_Name:"", S_Folder:""}, semSystemStateSemRecordsList:{}, semSystemStateFolderRecord:{F_Name:"", F_Folder:"", F_Min:1, F_Max:1, F_List:"", F_Current:missing value}}
> set semSystemStateFolderName of allMyProperties to "x"
>
> --etc.
>
> end SetPropValues
Well, that's interesting. Probably need a flag or something so you only call my SetPropValues() the first time through. A judicious use of {...} & (soft return) & {...} could probably make it easier to read.
Steve
------------------
OS X 10.6.8, AppleScript 2.1.2
_______________________________________________
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