Hi VIktor,
>Toninho, please provide a patch because I have no idea what
>HRESULT should be. An hbwinole.h is also needed if we
>want to publish C level functions. I'd appreciate if you could
>provide such patch and I will upload it.
I looked at my code and I think that HRESULT is not needed. A simple
HB_FUNC() that call hb_oleVariantToItem solve my problem.
But with a more extensive test here I found that this code doesn´t
work:
---cut---
procedure testolenew()
local oWord, oText
begin sequence
oWord = GetActiveObject( "Word.Application" )
recover
begin sequence
oWord = CreateObject( "Word.Application" )
recover
alert( "ERROR! Word not avialable." )
return
end sequence
end sequence
oWord:Documents:Add()
oText = oWord:Selection()
oText:Text = "OLE from Harbour" + hb_OSNewLine()
oText:Font:Name = "Arial"
oText:Font:Size = 36
oText:Font:Bold = .T.
oWord:Visible = .T.
oWord:WindowState = 1
return
---cut---
It fails in GetActiveObject(). I tried to see what is wrong in
GetActiveObject() but all seems to be fine. Mindaugas can you help
please ?
Regards,
Toninho.
_______________________________________________________
Yahoo! Mail - Sempre a melhor opção para você!
Experimente já e veja as novidades.
http://br.yahoo.com/mailbeta/tudonovo/
_______________________________________________
Harbour mailing list
[email protected]
http://lists.harbour-project.org/mailman/listinfo/harbour