OpenOffice.org Forum at OOoForum.orgThe OpenOffice.org Forum
 
 [Home]   [FAQ]   [Search]   [Memberlist]   [Usergroups]   [Register
 [Profile]   [Log in to check your private messages]   [Log in

calling functions in DLL

 
Post new topic   Reply to topic    OOoForum.org Forum Index -> OpenOffice.org Macros and API
View previous topic :: View next topic  
Author Message
Jobas
Guest





PostPosted: Wed Mar 19, 2003 3:11 pm    Post subject: calling functions in DLL Reply with quote

Hi

I have some problem about calling a ddl.

This is my module:

Declare Sub CalcZ Lib "xxxx.dll" (x As Double, TT As Double, PP As Double, Z As Double)
Function RhoGN(T As Double, P As Double)
Dim X(1 to 21) as double
X(1)=85.43799
X(2)=1.279
etc... till X(21)
Dim ZZ As Double, d As Double
Call CalcZ(X(1), T, P, ZZ, d)
RhoGN = d
End Function

I send X(1), T, P, XX and receive d from CalcZ

but it happens some problem when it sends that vector X(i) as reference( i believe because its not stated in value), the right value form CalcZ is not returned and some times my openoffice "crash".

Can someone help me?
Back to top
ManoelPego
Newbie
Newbie


Joined: 15 Sep 2003
Posts: 1

PostPosted: Thu Oct 02, 2003 12:30 pm    Post subject: calling dll Reply with quote

Hi !
I Have This Problem
code:
DECLARE Sub FW LIB "Win32API" ALIAS "FindWindow" (STRING,STRING) AS INTEGER
DECLARE Sub SF LIB "User32.dll" ALIAS "SetForegroundWindow" AS INTEGER
Sub Main
dim l1 As String
dim l2 As String
l1="0"
l2="Other Window"
hWnd =FW(l1,l2)
SF(hWnd) <---------error loading DLL
FreeLibrary("user32.dll" )
End Sub

can anyone help-me ?
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Post new topic   Reply to topic    OOoForum.org Forum Index -> OpenOffice.org Macros and API All times are GMT - 8 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group