Hi Ennio

Alle 00:15, giovedì 16 giugno 2005, Ennio-Sr ha scritto:
[...]
> Concerning the second part of the captioned subject,
> I started reading the Star Basic Guide and tried to run one  of the
> examples I found there; but I'm under the impression to have picked the
> wrong one for a start, as there is no way to make it run!
>
> This example was taken from p. 102 of the Italian version:
>
> Sub test_search
> '------------------------
>
> Dim SearchDesc As Object
> Dim Doc as Object
>
> Doc = StarDesktop.CurrentComponent       '[*]
[....]
> [*] BASIC runtime error: Property or method not found.

When you're in the IDE the CurrentComponent is the IDE itself !
therefore you must run the macro from a Writer document

> Searching the ML I saw a similar post by Daniel Carrera ("The StarBasic
> guide is boken" - 12 Aug 2004) which quoted  a different example; so 

The message you've picked has nothing to deal with your problem.

I think that if you would have searched for "StarDesktop.CurrentComponent 
Error" Instead of "Broken StarBasic guide" you would have had better luck

> my question is: what should I start reading (methodically) to basic Basic?

If I well remember, I've already answered to you privately, on a similar 
question.
anyway,  this is my personal advice:

1) the online help
2) The DevGuide , only chapter 11: "OpenOffice.org Basic and Dialogs"
(check it in the latest SDK)
3) the StarBasic manual from Sun
4) the Andrew Pitonyak's macro document 

strongly suggested also :
- Sun's Programmer's Tutorial
( http://api.openoffice.org/basic/man/tutorial/tutorial.pdf )
- the DevGuide (the remaining chapters)

Maybe purchasing a copy of "OpenOffice.org Macros Explained" would be also a 
good idea

All resources I've cited are listed here:
http://development.openoffice.org/#BASIC

Further:
- do practice! try everything  by yourself
- read and understand the basic libraries installed with Ooo
- read and understand the code from other. 
you can found lots of macros here http://www.ooomacros.org

Finally: 
when you are programming, save your time, use Xray (a smart package from 
Bernard Marcelly)


ciao
Paolo M




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

Reply via email to