• 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
Re: PDF view
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: PDF view


  • Subject: Re: PDF view
  • From: waynemelrose <email@hidden>
  • Date: Sun, 09 Jun 2013 14:33:44 +1000


On 09/06/2013, at 11:00 AM, Shane Stanley <email@hidden> wrote:

something like:

set thePDF to current application's PDFDocument's alloc()'s initWithURL_(urlOfFile)
tell thePDFView to setDocument_(thePDF)

-- 
Shane Stanley <email@hidden>
'AppleScriptObjC Explored' <www.macosxautomation.com/applescript/apps/>


Thanks Shane, that has me on the right path, but I'm having trouble compiling my app. At the moment I've connected a Referencing outlet to a property called thePDFView …  Thinking that's why it's not compiling.. ?

current error.. 

2013-06-09 14:31:46.567 DBTookKIT[6070:303] An uncaught exception was raised
2013-06-09 14:31:46.567 DBTookKIT[6070:303] *** -[NSKeyedUnarchiver decodeObjectForKey:]: cannot decode object of class (PDFView)
2013-06-09 14:31:46.569 DBTookKIT[6070:303] (
0   CoreFoundation                      0x00007fff98ac5b06 __exceptionPreprocess + 198
1   libobjc.A.dylib                     0x00007fff904723f0 objc_exception_throw + 43
2   CoreFoundation                      0x00007fff98ac58dc +[NSException raise:format:] + 204
3   Foundation                          0x00007fff9004cf33 _decodeObjectBinary + 2559
4   Foundation                          0x00007fff9004ddc6 -[NSKeyedUnarchiver _decodeArrayOfObjectsForKey:] + 1189
5   Foundation                          0x00007fff9004e338 -[NSArray(NSArray) initWithCoder:] + 538
6   Foundation                          0x00007fff9004cfe9 _decodeObjectBinary + 2741
7   Foundation                          0x00007fff9004c394 _decodeObject + 226
8   AppKit                              0x00007fff933df631 -[NSView initWithCoder:] + 976
9   Foundation                          0x00007fff9004cfe9 _decodeObjectBinary + 2741
10  Foundation                          0x00007fff9004c394 _decodeObject + 226
11  AppKit                              0x00007fff933deaef -[NSWindowTemplate initWithCoder:] + 3887
12  Foundation                          0x00007fff9004cfe9 _decodeObjectBinary + 2741
13  Foundation                          0x00007fff9004ddc6 -[NSKeyedUnarchiver _decodeArrayOfObjectsForKey:] + 1189
14  Foundation                          0x00007fff9004d7a1 -[NSSet(NSSet) initWithCoder:] + 544
15  Foundation                          0x00007fff9004cfe9 _decodeObjectBinary + 2741
16  Foundation                          0x00007fff9004c394 _decodeObject + 226
17  AppKit                              0x00007fff933d59e9 -[NSIBObjectData initWithCoder:] + 1976
18  Foundation                          0x00007fff9004cfe9 _decodeObjectBinary + 2741
19  Foundation                          0x00007fff9004c394 _decodeObject + 226
20  AppKit                              0x00007fff933d50f3 loadNib + 227
21  AppKit                              0x00007fff933d4679 +[NSBundle(NSNibLoading) _loadNibFile:nameTable:withZone:ownerBundle:] + 219
22  AppKit                              0x00007fff933d44ae -[NSBundle(NSNibLoading) loadNibNamed:owner:topLevelObjects:] + 200
23  AppKit                              0x00007fff933d428e +[NSBundle(NSNibLoading) loadNibNamed:owner:] + 360
24  AppKit                              0x00007fff933d0a2f NSApplicationMain + 398
25  DBTookKIT                           0x0000000100000f0a main + 74
26  libdyld.dylib                       0x00007fff922f07e1 start + 0
)
2013-06-09 14:31:46.570 DBTookKIT[6070:303] *** Terminating app due to uncaught exception 'NSInvalidUnarchiveOperationException', reason: '*** -[NSKeyedUnarchiver decodeObjectForKey:]: cannot decode object of class (PDFView)'
*** First throw call stack:
(
0   CoreFoundation                      0x00007fff98ac5b06 __exceptionPreprocess + 198
1   libobjc.A.dylib                     0x00007fff904723f0 objc_exception_throw + 43
2   CoreFoundation                      0x00007fff98ac58dc +[NSException raise:format:] + 204
3   Foundation                          0x00007fff9004cf33 _decodeObjectBinary + 2559
4   Foundation                          0x00007fff9004ddc6 -[NSKeyedUnarchiver _decodeArrayOfObjectsForKey:] + 1189
5   Foundation                          0x00007fff9004e338 -[NSArray(NSArray) initWithCoder:] + 538
6   Foundation                          0x00007fff9004cfe9 _decodeObjectBinary + 2741
7   Foundation                          0x00007fff9004c394 _decodeObject + 226
8   AppKit                              0x00007fff933df631 -[NSView initWithCoder:] + 976
9   Foundation                          0x00007fff9004cfe9 _decodeObjectBinary + 2741
10  Foundation                          0x00007fff9004c394 _decodeObject + 226
11  AppKit                              0x00007fff933deaef -[NSWindowTemplate initWithCoder:] + 3887
12  Foundation                          0x00007fff9004cfe9 _decodeObjectBinary + 2741
13  Foundation                          0x00007fff9004ddc6 -[NSKeyedUnarchiver _decodeArrayOfObjectsForKey:] + 1189
14  Foundation                          0x00007fff9004d7a1 -[NSSet(NSSet) initWithCoder:] + 544
15  Foundation                          0x00007fff9004cfe9 _decodeObjectBinary + 2741
16  Foundation                          0x00007fff9004c394 _decodeObject + 226
17  AppKit                              0x00007fff933d59e9 -[NSIBObjectData initWithCoder:] + 1976
18  Foundation                          0x00007fff9004cfe9 _decodeObjectBinary + 2741
19  Foundation                          0x00007fff9004c394 _decodeObject + 226
20  AppKit                              0x00007fff933d50f3 loadNib + 227
21  AppKit                              0x00007fff933d4679 +[NSBundle(NSNibLoading) _loadNibFile:nameTable:withZone:ownerBundle:] + 219
22  AppKit                              0x00007fff933d44ae -[NSBundle(NSNibLoading) loadNibNamed:owner:topLevelObjects:] + 200
23  AppKit                              0x00007fff933d428e +[NSBundle(NSNibLoading) loadNibNamed:owner:] + 360
24  AppKit                              0x00007fff933d0a2f NSApplicationMain + 398
25  DBTookKIT                           0x0000000100000f0a main + 74
26  libdyld.dylib                       0x00007fff922f07e1 start + 0
)
libc++abi.dylib: terminate called throwing an exception
(lldb)
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
applescriptobjc-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: PDF view
      • From: Shane Stanley <email@hidden>
References: 
 >PDF view (From: waynemelrose <email@hidden>)
 >Re: PDF view (From: Shane Stanley <email@hidden>)

  • Prev by Date: Re: PDF view
  • Next by Date: Re: PDF view
  • Previous by thread: Re: PDF view
  • Next by thread: Re: PDF view
  • Index(es):
    • Date
    • Thread