l函數原型:
int WINAPI ice pub _ dictionary code transfer(char * strdictionary filename,char *strSrc,char *strCode)
輸入:strDictionaryFilename的字典文件名。
StrSrc待定單詞
輸出:strCode strSrc對應的信息
返回代碼:
L VC連接庫模式語句
_ _ declspec(dll export)
int WINAPI ice pub _ dictionary code transfer(char * strdictionary filename,char *strSrc,char * strCode);
動態調用程序
VC示例代碼:
char strCode【1024】;
typedef int(WINAPI ice pub _ dictionary code transfer)(char * strdictionary filename,char *strSrc,char * strCode);
ice pub _ DICTIONARYCODETRANSFER * ice pub _ DICTIONARYCODETRANSFER = 0;
hin instance hDLLDrv = LoadLibrary(“icepubdll . dll“);
中頻(hDLLDrv)
{
ice pub _ dictionary code transfer =(ice pub _ dictionary code transfer *)GetProcAddress(hDLLDrv,“ice pub _ dictionary code transfer“);
}
if(ice pub _ dictionaryCodeTransfer)
IcePub_dictionaryCodeTransfer(“漢英詞典。txt“,“I“,strCode);
中頻(hDLLDrv)
免費圖書館(hDLLDrv);
AfxMessagBox(strCode);
VB示例代碼:
私有聲明函數ice pub _ dictionaryCodeTransfer Lib“ice pub dll . dll“(ByVal strDictionaryFilename作為字符串,ByVal strSrc作為字符串,ByVal strCode作為字符串)為整數
將a2設為整數
將strCode顯示為字符串
strCode = Space(1024)
a2 = ice pub _ dictionary code transfer(“漢英詞典。txt“,“I“,strCode)
MsgBox strCode
=============================
3.87 ice pub _ dictionaryCodeTransferString
批量轉換
l函數原型:
int WINAPI ice pub _ dictionaryCodeTransferString(char * strDictionaryFilename,char * strSrcString,char *strCode,int srcWordLen,char *strFenge)
輸入:strDictionaryFilename的字典文件名。
要處理的字符串
SrcWordLen要處理的字符串中每個單詞的長度(意味著必須是固定長度)
strFenge strCode中的每個結果都分隔字符串。
輸出:對應於strCode strSrcString的信息字符串。
返回代碼:
L VC連接庫模式語句
_ _ declspec(dll export)
int WINAPI ice pub _ dictionaryCodeTransferString(char * strDictionaryFilename,char * strSrcString,char *strCode,int srcWordLen,char * strFenge);
動態調用程序
VC示例代碼:
char strCode【1024】;
typedef int(WINAPI ice pub _ DICTIONARYCODETRANSFERSTRING)(char * strDictionaryFilename,char * strSrcString,char *strCode,int srcWordLen,char * strFenge);
ice pub _ DICTIONARYCODETRANSFERSTRING * ice pub _ DICTIONARYCODETRANSFERSTRING = 0;
hin instance hDLLDrv = LoadLibrary(“icepubdll . dll“);
中頻(hDLLDrv)
{
ice pub _ dictionaryCodeTransferString =(ice pub _ dictionaryCodeTransferString *)GetProcAddress(hDLLDrv,“ice pub _ dictionaryCodeTransferString“);
}
if(ice pub _ dictionaryCodeTransferString)
ice pub _ DictionaryCodeTransferString(“內部代碼字典。txt“,“憂愁“,2,strCode“,““;
中頻(hDLLDrv)
免費圖書館(hDLLDrv);
AfxMessagBox(strCode);
VB示例代碼:
私有聲明函數icePub _ dictionaryCodeTransferString Lib“icepubdll . dll“(ByVal strDictionaryFilename作為字符串,ByVal strSrcString作為字符串,ByVal srcWordLen作為整數,ByVal strCode作為字符串,ByVal strFenge作為字符串)作為整數
將a2設為整數
將strCode顯示為字符串
strCode = Space(1024)
a2 = ice pub _ dictionarycodetransferstring(“內部代碼字典。txt“,“陰雲“,2,strocode““)
MsgBox strCode
===========
拿著郵件。