OOP - Factory Scripts
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