Clipper/FiveWin - Sr.

 
Vista:

Sr.

Publicado por Oscar Santos (2 intervenciones) el 09/06/2009 21:13:47
Estimados:

Necesito saber si alguien tiene idea de por qué la aplicación, cuyos fuentes agrego más abajo, no responde después de llamar dinámicamente a la DLL unas 600 veces.

Compilado con CA Clipper 5.2e y linkeditado con Blinker 7.0

Desde ya muchas gracias

Oscar Santos

* --------------------------------------------------------------------------------------------------------------------
* Aplicación Principal
FUNCTION T

cDllName := "D.DLL" // Name of the DLL to use
cFunName := "DYNTEST" // Name of the function to call

FOR nI := 1 TO 1000

nLibHan = BLILIBLOD (cDllName) // Dynamically load the DLL

IF nLibHan > 32 // If it loaded successfully

nFunHan := BLIFUNHAN (nLibHan, cFunName) // Get the function handle

IF nFunHan <> 0 // If the function was found

xFunRes = BLIFUNCAL (nI, nFunHan) // Note that function handle is LAST

ELSE

? "DLL file", cDllName, "does not contain function", cFunName
?

ENDIF

BLILIBFRE (nLibHan) // Free the library when finished

ELSE

? "DLL file ", cDllName, "not found or failed to load"
?

ENDIF

NEXT

RETURN NIL
* --------------------------------------------------------------------------------------------------------------------

* --------------------------------------------------------------------------------------------------------------------
* DLL
FUNCTION DYNTEST(nPar1) // Function in a dynamically linked DLL

? nPar1, "This is DYNTEST in the DLL"

RETURN NIL
* --------------------------------------------------------------------------------------------------------------------

* --------------------------------------------------------------------------------------------------------------------
# T.LNK for CA-Clipper

bli exe ext # Create a DOS extended program
output t # Output EXE name

file t # List OBJ files here

defbegin # Module definition commands
name t # Indicate an EXE
defend # End module definition commands

nobell # No irritating beep
* --------------------------------------------------------------------------------------------------------------------

* --------------------------------------------------------------------------------------------------------------------
# D.LNK for CA-Clipper

output d # Output DLL name

file d # List OBJ files here

defbegin # Module definition commands
library d # Indicate a DLL
exetype windows 3.1
exports
DYNTEST # Export the DYNTEST function
defend # End module definition commands

nodeflib # No default libraries
nobell # No irritating beep
* --------------------------------------------------------------------------------------------------------------------

* --------------------------------------------------------------------------------------------------------------------
// T.RMK

COMVER := 52 // CA-Clipper compiler version number

#include "all.rmk" // Standard make file definitions

"$(OUTDIR) .exe" : "$(OBJDIR) .obj"
t.lnk
"t$(COMVER).lnk"
$(LNKCMD) @t$(COMVER) out $@ $(LNKOPT)

"$(OUTDIR)d.dll" : "$(OBJDIR)d.obj"
d.lnk
"d$(COMVER).lnk"
$(LNKCMD) @d$(COMVER) out $@ $(LNKOPT)

"$(OBJDIR)d.obj" : d.prg

"$(OBJDIR) .obj" : t.prg
* --------------------------------------------------------------------------------------------------------------------

* --------------------------------------------------------------------------------------------------------------------
// ALL.RMK
//
// This generic make file contains Blinker standard definitions which are
// included by all the CA-Clipper example make files include with Blinker.
//
// OBJ file directory
OBJDIR := .
// EXE and DLL file directory
OUTDIR := .

COMCMD := clipper // Compile command
COMOPT := /m /n /o$(OBJDIR) // Compile options

LNKCMD := blinker // Link command
LNKOPT := map s,a // Link options

#ifdef DEBUG // Determine if DEBUGging is enabled
COMOPT := $(COMOPT) /b
#end

.prg.obj:
$(COMCMD) $< $(COMOPT)

#stdout ""
#ifeq $(COMVER) 53
#stdout "Creating CA-Clipper 5.3 version"
#else
#ifeq $(COMVER) 52
#stdout "Creating CA-Clipper 5.2 version"
#else
#stdout "Creating CA-Clipper 5.01 version"
#endif
#endif
#stdout "Change COMVER in the make file for a different version"
#stdout ""

bldclp53.obj: // Blinker file
blxclp53.obj: // Blinker file
bldclp52.obj: // Blinker file
blxclp52.obj: // Blinker file
* --------------------------------------------------------------------------------------------------------------------
Valora esta pregunta
Me gusta: Está pregunta es útil y esta claraNo me gusta: Está pregunta no esta clara o no es útil
0
Responder

RE:Sr.

Publicado por gabriel pascual (1 intervención) el 19/06/2009 03:35:48
io que se...
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar