On 12.02.2012, at 17:59, Christiaan Hofman wrote:

> 
> On Feb 12, 2012, at 13:32, Christian Pleul wrote:
> 
>> On 12.02.2012, at 13:22, Christiaan Hofman wrote:
>> 
>>> 
>>> On Feb 12, 2012, at 13:01, Christian Pleul wrote:
>>> 
>>>> 
>>>> On 12.02.2012, at 10:08, Christiaan Hofman wrote:
>>>> 
>>>>> 
>>>>> On Feb 11, 2012, at 18:22, Christian Pleul wrote:
>>>>> 
>>>>>> Hi,
>>>>>> 
>>>>>> I tried the script DocInfo from the skim wiki [1] and it returns an 
>>>>>> error when running in the applescript editor. Since I never used 
>>>>>> applescript before, could somebody please tell me how to correct the 
>>>>>> script, because I need to count selected text in a pdf.
>>>>>> 
>>>>>> [1] 
>>>>>> http://sourceforge.net/apps/mediawiki/skim-app/index.php?title=AppleScript#User-Contributed_Scripts
>>>>>> 
>>>>>> 
>>>>>> Thank you in advance,
>>>>>> --
>>>>>>  Christian
>>>>> 
>>>>> 
>>>>> After the "set selText to..." line, add the following lines:
>>>>> 
>>>>>           if docText is missing value then
>>>>>                   set docText to ""
>>>>>           else
>>>>>                   set docText to docText as text
>>>>>           end if
>>>>>           if selText is missing value then
>>>>>                   set selText to ""
>>>>>           else
>>>>>                   set selText to selText as text
>>>>>           end if
>>>>> 
>>>>> 
>>>>> Christiaan
>>>> 
>>>> Worked for checking the entire doc. But when selecting e.g. a paragraph, 
>>>> the script produces the following error.
>>>> 
>>>> ------ error --------
>>>> error "Skim got an error: selection of document 1 doesn’t understand the 
>>>> get text for message." number -1708 from selection of document 1
>>>> ----------------------
>>>> 
>>>> Best
>>>> --
>>>>    Christian
>>>> 
>>> 
>>> Replace "selection for document 1" by "(get selection of document 1)", 
>>> including the parenthesis.
>>> 
>>> Christiaan
>> 
>> Thank you, works fine now. Only if I click the "More Info" button in the 
>> dialog, the following error message comes up in the applescript editor
>> 
>> ------ error --------
>> error "Can’t make «class ModD» of {modification date:date \"Sonntag, 12. 
>> Februar 2012 13:22:15\", «class Tags»:{}, «class titl»:\"ProLabIng\", «class 
>> Logi»:2.30302E+5, «class PCnt»:7, «class Prod»:\"pdfTeX-1.40.12\", «class 
>> Copy»:true, «class FlSz»:\"228.0 KB (230.302 bytes)\", «class Encr»:false, 
>> «class PgSz»:\"21.0 x 29.7 cm\", creation date:date \"Sonntag, 12. Februar 
>> 2012 13:22:15\", «class Crea»:\"LaTeX2e pdfLaTeX MacTeX2010 ST2 BibDesk\", 
>> «class Rate»:0.0, «class Auth»:\"Christian\", «class phys»:2.33472E+5, 
>> «class Prnt»:true, version:\"1.5\", file name:\"prolabating.pdf\"} into type 
>> Unicode text." number -1700 from «class ModD» of {modification date:date 
>> "Sonntag, 12. Februar 2012 13:22:15", «class Tags»:{}, «class 
>> titl»:"ProLabIng", «class Logi»:2.30302E+5, «class PCnt»:7, «class 
>> Prod»:"pdfTeX-1.40.12", «class Copy»:true, «class FlSz»:"228.0 KB (230.302 
>> bytes)", «class Encr»:false, «class PgSz»:"21.0 x 29.7 cm", creation 
>> date:date "Sonntag, 12. Februar 2012 13:22:15", «class Crea»:"LaTeX2e 
>> pdfLaTeX MacTeX2010 ST2 BibDesk", «class Rate»:0.0, «class 
>> Auth»:"Christian", «class phys»:2.33472E+5, «class Prnt»:true, 
>> version:"1.5", file name:"prolabating.pdf"} to Unicode text
>> ----------------------
>> 
>> Any idea on this issue?
>> 
>> Best
>> Christian
> 
> It seems to confuse two different "modification date" properties. I'll have 
> this avoided for the next release.
> 
> Christiaan

Thank you for your help, Christiaan. I will wait for the next release…


--
        Christian


"I hope to die
before I *have* to use Microsoft Word.",
Donald E. Knuth, 02-Oct-2001 in Tuebingen.

------------------------------------------------------------------------------
Virtualization & Cloud Management Using Capacity Planning
Cloud computing makes use of virtualization - but cloud computing 
also focuses on allowing computing to be delivered as a service.
http://www.accelacomm.com/jaw/sfnl/114/51521223/
_______________________________________________
Skim-app-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/skim-app-users

Reply via email to