• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
OOP - Factory Scripts
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

OOP - Factory Scripts


  • Subject: OOP - Factory Scripts
  • From: Jens Heimer <email@hidden>
  • Date: Tue, 18 Mar 2008 10:40:32 +0100
  • Thread-topic: OOP - Factory Scripts

Title: OOP - Factory Scripts
Hallo everyone,

I´ve got a new proble,  I haven’t figgerd out yet...

Could somebody explain me why,  when traiing tu run my testfile the script editor tells me that documentListe doesn’t know an add Handler?
It all worked fine, until i tried to seperate it in different files...

Thanks so far

Greatings Jens




Testfile.scpt

property UtilityFactory : load script file "Macintosh HD:Users:Jens:Desktop:DevFramework:Utilities:UtilityFactory.scpt"
property
ObjectFactory : load script file "Macintosh HD:Users:Jens:Desktop:DevFramework:Objects:ObjectFactory.scpt"
global
documentListe

on run
   set documentListe to (initListOfDocuments() of UtilityFactory)
   set obj1 to (initDocumentObject of ObjectFactory given docName:"Document1", docID:1)
   add of documentListe given documentObject:obj1
end
run





UtilityFactory.scpt

property
listOfDocuments : load script file "Macintosh HD:Users:Jens:Desktop:DevFramework:Utilities:Scripte:Liste.scpt"

on initListOfDocuments()
   script liste
       
property parent : listOfDocuments
   
end script
   
return liste
end initListOfDocuments


Liste.scpt

script
listOfDocuments
   property listeOfDocuments : {}
   on add given documentObject:obj
       set end of listeOfDocuments to obj
   end add
end script
 _______________________________________________
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

  • Follow-Ups:
    • Re: OOP - Factory Scripts
      • From: Philip Aker <email@hidden>
  • Prev by Date: Re: Toxic Soup and Enough for all
  • Next by Date: Re: OOP - Factory Scripts
  • Previous by thread: Re: When does "item x of" auto-iterate?
  • Next by thread: Re: OOP - Factory Scripts
  • Index(es):
    • Date
    • Thread