Amiguinhos,
As funções
GetProfileString e
WriteProfileString fazem parte da
kernel32.dll e servem para pegar e escrever informações no registro.
Como não encontro o site que tinha a referencia de cada biblioteca, cada função e o código de cada uma, pois ele foi hackeado recentemente, não tenho como lhe informar com exatidão qual biblioteca o mesmo necessita.
Olhando o
win_prn2.c não a encontrei, mas sim referencia a função real da API.
Já no código abaixo podemos notar a menção de
what32 e talvez pensar que a mesma foi portada para Harbour e que provavelmente exista uma
hb_what32:
Código: Selecionar todos
/*
* $Id: winini.prg 8045 2007-11-25 18:36:59Z vouchcac $
*/
// WHAT32
* Useful .INI Interface enhancements
// Get from private Ini
*-----------------------------------------------------------------------------*
FUNCTION GetPrivateProfileLog( cSection, cEntry, lDefault, cFile )
LOCAL cDefault:=IF(lDefault,"YES","NO")
LOCAL cRet:=GetPrivateProfileString(cSection, cEntry, cDefault, cFile )
RETURN(UPPER(cRet) $ "YESON1")
*-----------------------------------------------------------------------------*
FUNCTION GetPrivateProfileFloat(cSection, cEntry, nDefault, cFile )
LOCAL cDefault:=STR(nDefault)
LOCAL cRet:=GetPrivateProfileString(cSection, cEntry, cDefault, cFile )
RETURN(VAL(cRet))
*-----------------------------------------------------------------------------*
FUNCTION GetPrivateProfileDate( cSection, cEntry, dDefault, cFile )
LOCAL cDefault:=DTOS( dDefault )
LOCAL cRet:=GetPrivateProfileString(cSection, cEntry, cDefault, cFile )
RETURN(STOD( cRet ))
// Get from Win.Ini
*-----------------------------------------------------------------------------*
FUNCTION GetProfileLog( cSection, cEntry, lDefault )
LOCAL cDefault:=IF(lDefault,"YES","NO")
LOCAL cRet:=GetProfileString(cSection, cEntry, cDefault )
RETURN(UPPER(cRet) $ "YESON1")
*-----------------------------------------------------------------------------*
FUNCTION GetProfileFloat(cSection, cEntry, nDefault )
LOCAL cDefault:=STR(nDefault)
LOCAL cRet:=GetProfileString(cSection, cEntry, cDefault )
RETURN(VAL(cRet))
*-----------------------------------------------------------------------------*
FUNCTION GetProfileDate( cSection, cEntry, dDefault )
LOCAL cDefault:=DTOS( dDefault )
LOCAL cRet:=GetProfileString(cSection, cEntry, cDefault )
RETURN(STOD( cRet ))
// Write to Private Ini
*-----------------------------------------------------------------------------*
FUNCTION WritePrivateProfileInt( cSection, cEntry, nData, cFile )
RETURN( WritePrivateProfileString( cSection, cEntry, STR( INT(nData) ), cFile ) )
*-----------------------------------------------------------------------------*
FUNCTION WritePrivateProfileLog( cSection, cEntry, lData, cFile )
RETURN( WritePrivateProfileString( cSection, cEntry, IF(lData,"Yes","No") , cFile ) )
*-----------------------------------------------------------------------------*
FUNCTION WritePrivateProfileFloat( cSection, cEntry, nData, cFile )
RETURN( WritePrivateProfileString( cSection, cEntry, STR( nData ) , cFile ) )
*-----------------------------------------------------------------------------*
FUNCTION WritePrivateProfileDate( cSection, cEntry, dData, cFile )
RETURN( WritePrivateProfileString( cSection, cEntry, DTOS( dData ) , cFile ) )
// Write to Win.Ini
*-----------------------------------------------------------------------------*
FUNCTION WriteProfileLog( cSection, cEntry, lData )
RETURN( WriteProfileString( cSection, cEntry, IF(lData,"Yes","No") ) )
*-----------------------------------------------------------------------------*
FUNCTION WriteProfileFloat( cSection, cEntry, nData )
RETURN( WriteProfileString( cSection, cEntry, STR( nData ) ) )
*-----------------------------------------------------------------------------*
FUNCTION WriteProfileDate( cSection, cEntry, dData )
RETURN( WriteProfileString( cSection, cEntry, DTOS( dData ) ) )
*-----------------------------------------------------------------------------*
FUNCTION WriteProfileInt( cSection, cEntry, nData )
RETURN( WriteProfileString( cSection, cEntry, STR( INT(nData) ) ) )
Portanto lhe afirmar com certeza qual a biblioteca correta não dá sem uma referências dos autores.
Para não ficar te devendo veja um pedaço de meu
buildh.bat:
Código: Selecionar todos
echo %hdirl%\hbrtl.lib + >> b32.bc
echo %hdirl%\hbvm.lib + >> b32.bc
echo %hdirl%\%GT%.lib + >> b32.bc
echo %hdirl%\gtstd.lib + >> b32.bc
echo %hdirl%\gtcgi.lib + >> b32.bc
echo %hdirl%\hblang.lib + >> b32.bc
echo %hdirl%\hbmacro.lib + >> b32.bc
echo %hdirl%\hbrdd.lib + >> b32.bc
echo %hdirl%\rddntx.lib + >> b32.bc
echo %hdirl%\rddcdx.lib + >> b32.bc
echo %hdirl%\rddfpt.lib + >> b32.bc
echo %hdirl%\rddsql.lib + >> b32.bc
echo %hdirl%\sddodbc.lib + >> b32.bc
echo %hdirl%\sddmy.lib + >> b32.bc
echo %hdirl%\hbsix.lib + >> b32.bc
echo %hdirl%\hbdebug.lib + >> b32.bc
echo %hdirl%\hbcommon.lib + >> b32.bc
echo %hdirl%\hbpp.lib + >> b32.bc
echo %hdirl%\hbcpage.lib + >> b32.bc
echo %hdirl%\hbwin.lib + >> b32.bc
echo %hdirl%\hbcplr.lib + >> b32.bc
echo %hdirl%\hbct.lib + >> b32.bc
echo %hdirl%\hbnf.lib + >> b32.bc
echo %hdirl%\hbextern.lib + >> b32.bc
echo %hdirl%\xhb.lib + >> b32.bc
echo %hdirl%\hbtip.lib + >> b32.bc
echo %fwh%\lib\adordd.lib + >> b32.bc
echo %hdirl%\hbusrrdd.lib + >> b32.bc
echo %hdirl%\hboleaut.lib + >> b32.bc
echo %hdirl%\hbhpdf.lib + >> b32.bc
echo %hdirl%\libhpdf.lib + >> b32.bc
echo %hdirl%\hbzebra.lib + >> b32.bc
echo %bcdir%\lib\cw32.lib + >> b32.bc
echo %bcdir%\lib\uuid.lib + >> b32.bc
echo %bcdir%\lib\import32.lib + >> b32.bc
echo %bcdir%\lib\ws2_32.lib + >> b32.bc
echo %bcdir%\lib\pcrepos.lib + >> b32.bc
echo %bcdir%\lib\psdk\ole32.lib + >> b32.bc
echo %bcdir%\lib\psdk\gdi32.lib + >> b32.bc
echo %bcdir%\lib\psdk\odbc32.lib + >> b32.bc
echo %bcdir%\lib\psdk\user32.lib + >> b32.bc
echo %bcdir%\lib\psdk\nddeapi.lib + >> b32.bc
echo %bcdir%\lib\psdk\iphlpapi.lib + >> b32.bc
echo %bcdir%\lib\psdk\msimg32.lib + >> b32.bc
echo %bcdir%\lib\psdk\psapi.lib + >> b32.bc
echo %bcdir%\lib\psdk\shell32.lib + >> b32.bc
echo %bcdir%\lib\psdk\rasapi32.lib, >> b32.bc
Geralmente estas funções estão na
hbWin.lib