使用方法:
本DLL只有两个函数,函数原型如下:
//获得拼音
//参数依次为: 拼音缓存区,要转换的字符,分隔符
BOOL WINAPI GetPinYin(PCHAR pBuf,PCHAR pStr,PCHAR pSeparator)implementation
procedure GetPinYin(pbuf:string;pStr:string ;pSeparator:string ); cdecl StdCall; external 'PinYin.dll';{$R *.dfm}procedure TForm1.Button1Click(Sender: TObject);
var pbuf:string;
begin
getpinyin(pbuf,edit1.text,' ') ;
showmessage(pbuf);
end;出错提示如下:
project project1.exe raised exception class eaccessviolation with message 'access violation at address 100013A0 in module 'pinyin.dll'. write of address 00000000'.process stopped.use step or run to continue.
本DLL只有两个函数,函数原型如下:
//获得拼音
//参数依次为: 拼音缓存区,要转换的字符,分隔符
BOOL WINAPI GetPinYin(PCHAR pBuf,PCHAR pStr,PCHAR pSeparator)implementation
procedure GetPinYin(pbuf:string;pStr:string ;pSeparator:string ); cdecl StdCall; external 'PinYin.dll';{$R *.dfm}procedure TForm1.Button1Click(Sender: TObject);
var pbuf:string;
begin
getpinyin(pbuf,edit1.text,' ') ;
showmessage(pbuf);
end;出错提示如下:
project project1.exe raised exception class eaccessviolation with message 'access violation at address 100013A0 in module 'pinyin.dll'. write of address 00000000'.process stopped.use step or run to continue.
IwantFlay(我很爱她!!!!!!!!!!) 的方法和我原来的是出现同一错误
function GetPinYin(pBuf, pStr, pSeparator :PChar):BOOL;stdcall;external 'PinYin.dll';