... instance->MyMethod(param);
}
// C Application
#include <windows.h>
typedef int (*CallDotNetFunction)(int);
int main() {
HMODULE hDll = LoadLibrary("Wrapper.dll");
CallDotNetFunction func = (CallDotNetFunction)GetProcAddress(hDll, "CallDotNetFunction");
int result = func(42 ...
Search found 340 matches: loadlibrary
Searched query: loadlibrary
- Tue Jan 21, 2025 4:52 am
- Forum: FiveWin for Harbour/xHarbour
- Topic: How to convert LIB from .NET dll file
- Replies: 2
- Views: 5902
- Sun Jan 19, 2025 7:12 pm
- Forum: FiveWin for Harbour/xHarbour
- Topic: How to convert LIB from .NET dll file
- Replies: 2
- Views: 5902
Re: How to convert LIB from .NET dll file
... instance->MyMethod(param);
}
// C Application
#include <windows.h>
typedef int (*CallDotNetFunction)(int);
int main() {
HMODULE hDll = LoadLibrary("Wrapper.dll");
CallDotNetFunction func = (CallDotNetFunction)GetProcAddress(hDll, "CallDotNetFunction");
int result = func(42 ...
}
// C Application
#include <windows.h>
typedef int (*CallDotNetFunction)(int);
int main() {
HMODULE hDll = LoadLibrary("Wrapper.dll");
CallDotNetFunction func = (CallDotNetFunction)GetProcAddress(hDll, "CallDotNetFunction");
int result = func(42 ...
- Tue Oct 15, 2024 1:45 am
- Forum: FiveWin for Harbour/xHarbour
- Topic: How to add 2d barcode to fastreport or fwh/harbour?
- Replies: 7
- Views: 1326
Re: How to add 2d barcode to fastreport or fwh/harbour?
1.
FUNCTION img2dbarcode()
local h2d
private hlib
hLib = LOADLIBRARY( "zint.dll" )
h2d:=ZBarcode_Create()
//// h2d should has datas: symbology,height,width,bitmap,...
?h2d:symbology
// error: method symbology does not exsist
ZBarcode_Encode_and_buffer(h2d,"abc45",5,0)
//error: will hangup ...
FUNCTION img2dbarcode()
local h2d
private hlib
hLib = LOADLIBRARY( "zint.dll" )
h2d:=ZBarcode_Create()
//// h2d should has datas: symbology,height,width,bitmap,...
?h2d:symbology
// error: method symbology does not exsist
ZBarcode_Encode_and_buffer(h2d,"abc45",5,0)
//error: will hangup ...
- Mon Apr 01, 2024 3:38 pm
- Forum: FiveWin for Harbour/xHarbour
- Topic: Error Usando LoadLib32 o LoadLib - Retorno Puntero
- Replies: 3
- Views: 1195
Error Usando LoadLib32 o LoadLib - Retorno Puntero
... esto provoca que al llamar a las funciones internas de las DLL estas arrojen error.
He probado con los samples que vienen en FWH (Que usan LoadLibrary or LoadLib32) y hacen lo mismo , por ejemplo EMF.PRG
Error
Time from start: 0 hours 0 mins 0 secs
Error occurred at: 04/01/24, 11:43:31 ...
He probado con los samples que vienen en FWH (Que usan LoadLibrary or LoadLib32) y hacen lo mismo , por ejemplo EMF.PRG
Error
Time from start: 0 hours 0 mins 0 secs
Error occurred at: 04/01/24, 11:43:31 ...
- Tue Feb 13, 2024 11:20 am
- Forum: FiveWin for Harbour/xHarbour
- Topic: RC to PRG generator
- Replies: 23
- Views: 3549
Re: RC to PRG generator
... for it:
simply rename your RC file as rctoprg.rc and build rctoprg.prg
If you keep your dialogs inside a DLL then replace GetInstance() for LoadLibrary( "yourdll.dll" )
This example and the new C code listed at the bottom will be included in next FWH build.
rctoprg.prg
#include "FiveWin.ch ...
simply rename your RC file as rctoprg.rc and build rctoprg.prg
If you keep your dialogs inside a DLL then replace GetInstance() for LoadLibrary( "yourdll.dll" )
This example and the new C code listed at the bottom will be included in next FWH build.
rctoprg.prg
#include "FiveWin.ch ...
- Thu Dec 21, 2023 10:51 am
- Forum: FiveWin for Harbour/xHarbour
- Topic: Using Microsoft AI Phi-2 from FWH
- Replies: 51
- Views: 16154
Re: Using Microsoft AI Phi-2 from FWH
hi Antonio,
Could you kindly adapt this code to HMG ?
i´m not sure about "Callback" under HMG
will FWH CODE work when "LoadLibrary", "llama64.dll" or do i need DLL FUNCTION :?:
Dear Jimmy,
Does HMG support DLL FUNCTION ? or similar ? Or should we use Harbour default DLL management functions ...
Could you kindly adapt this code to HMG ?
i´m not sure about "Callback" under HMG
will FWH CODE work when "LoadLibrary", "llama64.dll" or do i need DLL FUNCTION :?:
Dear Jimmy,
Does HMG support DLL FUNCTION ? or similar ? Or should we use Harbour default DLL management functions ...
- Thu Dec 21, 2023 10:26 am
- Forum: FiveWin for Harbour/xHarbour
- Topic: Using Microsoft AI Phi-2 from FWH
- Replies: 51
- Views: 16154
Re: Using Microsoft AI Phi-2 from FWH
hi Antonio,
will FWH CODE work when "LoadLibrary", "llama64.dll" or do i need DLL FUNCTION![Question :?:](./images/smilies/icon_question.gif)
i´m not sure about "Callback" under HMGAntonio Linares wrote: Could you kindly adapt this code to HMG ?
will FWH CODE work when "LoadLibrary", "llama64.dll" or do i need DLL FUNCTION
![Question :?:](./images/smilies/icon_question.gif)
- Thu Oct 19, 2023 4:51 pm
- Forum: FiveWin para Harbour/xHarbour
- Topic: PDF en aplicacion con RICHEDIT
- Replies: 13
- Views: 1702
Re: PDF en aplicacion con RICHEDIT
... 5.40
Copyright (c) 1990, 1999 Inprise Corporation. All rights reserved.
Turbo Incremental Link 5.00 Copyright (c) 1997, 2000 Borland
Fatal: Unable to open file 'GDIPLUS.LIB'
* Linking errors *
Ademas si esta libreria : LoadLibrary( "riched20.dll" ) debe de estar en la carpeta de fwh\samples, no esta
Copyright (c) 1990, 1999 Inprise Corporation. All rights reserved.
Turbo Incremental Link 5.00 Copyright (c) 1997, 2000 Borland
Fatal: Unable to open file 'GDIPLUS.LIB'
* Linking errors *
Ademas si esta libreria : LoadLibrary( "riched20.dll" ) debe de estar en la carpeta de fwh\samples, no esta
- Tue Aug 08, 2023 4:07 am
- Forum: FiveWin for Harbour/xHarbour
- Topic: xHarbour Commercial and latest FWH
- Replies: 3
- Views: 676
Re: xHarbour Commercial and latest FWH
Dear Randal,
xHarbour provides a function LoadLibrary() that returns a pointer, thats why we modified dll.ch to check if a pointer is returned and then we turn it into a number.
When you link FWH dll.c then you are using FWH LoadLibrary() that retuns a number and everything is correct.
So, again ...
xHarbour provides a function LoadLibrary() that returns a pointer, thats why we modified dll.ch to check if a pointer is returned and then we turn it into a number.
When you link FWH dll.c then you are using FWH LoadLibrary() that retuns a number and everything is correct.
So, again ...
- Mon Aug 07, 2023 5:03 pm
- Forum: FiveWin for Harbour/xHarbour
- Topic: xHarbour Commercial and latest FWH
- Replies: 3
- Views: 676
Re: xHarbour Commercial and latest FWH
I put together a small test and if works fine with Fivewin and Harbour (Borland) but not xBuilder/xHarbour.
The problem is with LoadLibrary, this function returns a pointer instead of a numeric value.
I'm linking these libs:
\fwh\lib\xfw.lib
\xhb\lib\xHBZIP.LIB
\xhb\lib\xHBZipDll.lib
\xhb\c_lib\win ...
The problem is with LoadLibrary, this function returns a pointer instead of a numeric value.
I'm linking these libs:
\fwh\lib\xfw.lib
\xhb\lib\xHBZIP.LIB
\xhb\lib\xHBZipDll.lib
\xhb\c_lib\win ...
- Sat Aug 05, 2023 2:06 am
- Forum: FiveWin for Harbour/xHarbour
- Topic: xHarbour Commercial and latest FWH
- Replies: 3
- Views: 676
xHarbour Commercial and latest FWH
... however, I'm getting an error in a particular function.
I'm using a 3rd party lib for emailing. This is the code in question:
hSmtp := LoadLibrary("CSMTPAV9.dll")
// Must initialize first. Should return true
lSmtpInit := SmtpInitialize(CSTOOLS9_LICENSE_KEY)
DLL FUNCTION SmtpInitialize ...
I'm using a 3rd party lib for emailing. This is the code in question:
hSmtp := LoadLibrary("CSMTPAV9.dll")
// Must initialize first. Should return true
lSmtpInit := SmtpInitialize(CSTOOLS9_LICENSE_KEY)
DLL FUNCTION SmtpInitialize ...
- Wed Apr 26, 2023 8:13 am
- Forum: FiveWin for Harbour/xHarbour
- Topic: Error al leer un dll
- Replies: 19
- Views: 3435
Re: Error al leer un dll
Hola Antonio, el error lo tengo en el loadllibrary, lo que devuelve:
hDll := LoadLibrary( "winfis32.dll" )
el hDll = 0x0000000 si la librería existe o 0x0 si no existe, en lugar de devolver 0 si es correcto o el -1
Saludos
Jorge
Si hDLL vale cero (da igual que esté escrito en hexadecimal ...
hDll := LoadLibrary( "winfis32.dll" )
el hDll = 0x0000000 si la librería existe o 0x0 si no existe, en lugar de devolver 0 si es correcto o el -1
Saludos
Jorge
Si hDLL vale cero (da igual que esté escrito en hexadecimal ...
- Mon Apr 24, 2023 11:44 am
- Forum: FiveWin for Harbour/xHarbour
- Topic: Error al leer un dll
- Replies: 19
- Views: 3435
Re: Error al leer un dll
jpcavagnaro wrote:Hola Antonio, el error lo tengo en el loadllibrary, lo que devuelve:
hDll := LoadLibrary( "winfis32.dll" )
el hDll = 0x0000000 si la librería existe o 0x0 si no existe, en lugar de devolver 0 si es correcto o el -1
Saludos
Jorge
- Sat Apr 22, 2023 1:49 pm
- Forum: FiveWin for Harbour/xHarbour
- Topic: Error al leer un dll
- Replies: 19
- Views: 3435
Re: Error al leer un dll
Hola Antonio, el error lo tengo en el loadllibrary, lo que devuelve:
hDll := LoadLibrary( "winfis32.dll" )
el hDll = 0x0000000 si la librería existe o 0x0 si no existe, en lugar de devolver 0 si es correcto o el -1
Saludos
Jorge
Si hDLL vale cero (da igual que esté escrito en hexadecimal ...
hDll := LoadLibrary( "winfis32.dll" )
el hDll = 0x0000000 si la librería existe o 0x0 si no existe, en lugar de devolver 0 si es correcto o el -1
Saludos
Jorge
Si hDLL vale cero (da igual que esté escrito en hexadecimal ...
- Sat Apr 22, 2023 11:35 am
- Forum: FiveWin for Harbour/xHarbour
- Topic: Error al leer un dll
- Replies: 19
- Views: 3435
Re: Error al leer un dll
Hola Antonio, el error lo tengo en el loadllibrary, lo que devuelve:
hDll := LoadLibrary( "winfis32.dll" )
el hDll = 0x0000000 si la librería existe o 0x0 si no existe, en lugar de devolver 0 si es correcto o el -1
Saludos
Jorge
hDll := LoadLibrary( "winfis32.dll" )
el hDll = 0x0000000 si la librería existe o 0x0 si no existe, en lugar de devolver 0 si es correcto o el -1
Saludos
Jorge