Вниз
Скачать: CL | DM;

Слияние файлов   Найти похожие ветки 

← →
Allex   (2003-04-08 11:38) [0]

Как соединить два бинарных файла при помощи win api(если можно пример)


← →
jack128 ©   (2003-04-08 11:52) [1]

var h1, h2 : Thandle;
ActualBytes : Cardinal;
temp : string;
begin
h1 :=CreateFile(filename1,
GENERIC_WRITE,
0,
nil,
OPEN_EXISTING,
FILE_ATTRIBUTE_NORMAL,
0);
if h1=INVALID_HANDLE_VALUE then Exit;
h2 := CreateFile(filename1,
GENERIC_READ,
0,
nil,
OPEN_EXISTING,
FILE_ATTRIBUTE_NORMAL,
0);
if h2=INVALID_HANDLE_VALUE then begin
CloseHAndle(h1);
Exit;
end;
SetLength(temp,GetFileSize(h2,nil));
SetFilePointer(h1,0,nil,FILE_END);
if ReadFile(h2,Pchar(temp)^,Length(temp),Actualbytes,nil) and
ActualBytes = Length(temp) and
WriteFile(h1,Pchar(temp)^,Length(temp),Actualbytes,nil) and
ActualBytes = Length(temp) then ShowMessage("Yra!!!");
CloseHandle(h1);
CloseHandle(h2);
end;



Страницы: 1 вся ветка

Скачать: CL | DM;



Память: 0.44 MB
Время: 0.011 c
11-13107
Alexander
2002-09-12 10:22
2003.06.05
Как установить для нескольких кнопок одну радиогруппу?


8-13334
Alexanders
2003-02-22 13:28
2003.06.05
Проигрывание и навигация по wav файлу из памяти


8-13326
sergey bala
2003-02-20 09:59
2003.06.05
Произношение слов на русском якыке


1-13318
HardClubber
2003-05-25 10:43
2003.06.05
Параметры к приложению


1-13160
KIE
2003-05-14 15:41
2003.06.05
Delphi и и Excel




   Наверх