[INCLUDE]
CallFunction

[CODE]
#If (CallFunction_FlagA And &H100&) = &H100& Then
Public Function CallFunction_Indirect(ByVal DllHandle As Long, ByVal FunctionName As Variant, ByVal IsStdCall As Boolean, ParamArray FunctionParams()) As Long
#Else
Public Function CallFunction_Indirect(ByVal DllHandle As Long, ByVal FunctionName As Variant, ParamArray FunctionParams()) As Long
#End If
  Dim xLong1 As Long

  ReDim sLongA1(UBound(FunctionParams()) + 1&)
  For xLong1 = 0& To UBound(FunctionParams())
    sLongA1(xLong1) = FunctionParams(xLong1)
    Next
    
  If Not VarType(FunctionName) = vbString Then FunctionName = "#" + CStr(Val(FunctionName))
  xLong1 = GetProcAddress(DllHandle, CStr(FunctionName))
  If Not xLong1 = 0& Then
    #If (CallFunction_FlagA And &H100&) = &H100& Then
      CallFunction_Indirect = CallWindowProcAnsi(PrepareCode(xLong1, IsStdCall), 0, 0, 0, 0)
      #Else
      CallFunction_Indirect = CallWindowProcAnsi(PrepareCode(xLong1), 0, 0, 0, 0)
      #End If
    End If
    
  ReDim sLongA1(0&)
  ReDim sByteA1(0&)
  End Function