Hmmm. Is there any documentation? I'm having trouble with the macro:
None of which I am aware. I just loaded the macro and looked at it in the IDE.
I'm running OOo 2.2 on Win XP Pro. I downloaded and installed the macro in
my "default macro library". I create and save a Writer .odt file with all
paragraphs in "Text body" style. I then tried two different things:

1. Run the macro "Analyse text". I get the following error message:
==== begin error message ===
A Scripting Framework error occurred while running the Basic script
Readability.Readability.AnalyzeText.

Message: wrong number of parameters!
      [OK}
==== end error message ===

2. After closing and re-opening the document I ran the "initialise" macro
within the Readability module. I get the following error message:
==== begin error message ===
BASIC runtime error.
Sub-procedure or function procedure not defined.
    [OK]
==== end error message ===
There is a window displaying source code. One line is highlighted:
Dialog.getControl("WordsPerSentence").Text  =  Round(nWords / nSentences, 1)

This is within a block of code:
===== begin code ====
  If (nSentences <> 0) AND (nWords <> 0) Then
    Dialog.getControl("WordsPerSentence").Text = Round(nWords / nSentences,
1)
    Dialog.getControl("SyllablesPerWord").Text = Round(nSyllables / nWords,
2)
  End If
========= end code =====

which is itself with a subroutine named "ResultsDialog"



What am I doing wrong, please?
What happens if you use Tools | Addons | Readability

You should be able to run the "Main" macro

Sub Main
 GlobalScope.BasicLibraries.LoadLibrary("Tools")
 DialogLibraries.LoadLibrary("Readability")
 bCancel = FALSE
 Initialize
End Sub

If nothing is selected, it will ask if you want to inspect the entire document.

--
Andrew Pitonyak
My Macro Document: http://www.pitonyak.org/AndrewMacro.odt
My Book: http://www.hentzenwerke.com/catalog/oome.htm
Info:  http://www.pitonyak.org/oo.php
See Also: http://documentation.openoffice.org/HOW_TO/index.html


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to