-----Messaggio Originale----- Da: "Mindaugas Kavaliauskas" <[email protected]>
A: "Harbour Project Main Developer List." <[email protected]>
Data invio: mercoledì 16 settembre 2009 1.14
Oggetto: Re: [Harbour] Another OLE problem


I also thought it should work with CreateObject(), but I know WIN_OLECREATEOBJECT() works, so, I suggested a tested solution.

Can you try using CREATEOBJECT() instead?

We had some compatibility layer in hbwin/legacy.prg. Please look into it and fix it if it is necessary.

As I just wrote in my previous message, it can be linked.

But I know that, if :StoryRanges is a real OLE collection, when :StoryRanges:Item(5) should work for sure in both xHarbour and Harbour, because :Item() is OLE method defined for all collections.

With the following sample

FUNCTION MAIN()

   LOCAL oWord

   oWord = WIN_OLECREATEOBJECT( "Word.Application" )

   oWord:Documents:Add()

   ? oWord:ActiveDocument:StoryRanges( 5 )

   oWord:Visible = .T.

   RETURN NIL

I get

Error BASE/3012  Argument error: STORYRANGES
Called from WIN_OLEAUTO:STORYRANGES(0)
Called from MAIN(9)

while it still works fine using xHarbour.

EMG

--
EMAG Software Homepage:     http://www.emagsoftware.it
The EMG's ZX-Spectrum Page: http://www.emagsoftware.it/spectrum
The Best of Spectrum Games: http://www.emagsoftware.it/tbosg
The EMG Music page: http://www.emagsoftware.it/emgmusic
_______________________________________________
Harbour mailing list
[email protected]
http://lists.harbour-project.org/mailman/listinfo/harbour

Reply via email to