I'm translating many macros from VBA to openoffice basic: the only my problem 
is to translate the VBA function evaluate(....), for example 

x="3*8+4^2".
y=Evaluate(x)

I need this function since I have to show the details of my calculations.
I've solved the problem as follow:

Function cal(testo As String) As Double
   oObjFactory = createUnoService( "com.sun.star.bridge.OleObjectFactory" )
   RInterface = oObjFactory.createInstance( "StatConnectorSrv.StatConnector" )
   call RInterface.Init("R")
   cal = RInterface.Evaluate(testo)
End Function

BUT IN THIS WAY MY CALC SHEETS ARE VERY SLOW !!!!!
Thank you in advance

Sandro

Reply via email to