最好能详细说明这些函数中每个参数的含义!谢谢了!
function FileSeek(Handle: Integer;Offset: Longint;Origin: Integer):Longint;
function FileRead(Handle:Integer; var Buffer;Count:Longint):Longint;
function FileOpen(const FileName: string; Mode:Word): Integer;
function FileSeek(Handle: Integer;Offset: Longint;Origin: Integer):Longint;
function FileRead(Handle:Integer; var Buffer;Count:Longint):Longint;
function FileOpen(const FileName: string; Mode:Word): Integer;
解决方案 »
- DELPHI 2009 使用DevExpressVCLv42的ExpressBars,运行时说DesignEditors.dcu找不到。
- 急急急!!!公司要我开发这样一套系统,大家给点意见!!!!
- DXDBGRID
- QuickReport中使用QRDBRichText1控件显示Memo型字段为何退出时候报“System error,Code:1400.相互身份验证失败,该服务器在域控制器的密
- 配置文件问题!!!出现没有足够实用参数问题
- 怎么写取数据表中各字段的类型?
- 怎么在DELPHI中动态建立ODBC 的SQL SERVER的DSN?
- 识别源码控件问题!!!!!高手来看看!
- dx快来看看delphi如何将系统时间转换成UTC时间
- 谁知道下载程序如(netants)的多线程原理?
- is not a valid smalldatetime..
- 数据通信问题
iFileHandle: Integer;
iFileLength: Integer;
iBytesRead: Integer;
Buffer: PChar;
i: Integer
begin
if OpenDialog1.Execute then
begin
try
iFileHandle := FileOpen(OpenDialog1.FileName, fmOpenRead);
iFileLength := FileSeek(iFileHandle,0,2);
FileSeek(iFileHandle,0,0);
Buffer := PChar(AllocMem(iFileLength + 1));
iBytesRead := FileRead(iFileHandle, Buffer^, iFileLength); FileClose(iFileHandle);
for i := 0 to iBytesRead-1 do
begin
StringGrid1.RowCount := StringGrid1.RowCount + 1;
StringGrid1.Cells[1,i+1] := Buffer[i];
StringGrid1.Cells[2,i+1] := IntToStr(Integer(Buffer[i]));
end;
finally
FreeMem(Buffer);
end;
end;
end;