摘要: unit zip_main;{$mode objfpc}{$H+}interfaceuses Classes, SysUtils, FileUtil, Forms, Controls, Graphics, Dialogs, StdCtrls, Buttons, zstream, Zipper,Base64;type { TForm1 } TForm1 = class(TForm) Button1: TButton; SelectDirectoryDialog1: TSelectDirectoryDialog; unZipBtn: TBitBtn; localDirLbl: TLabel; Op 阅读全文
posted @ 2012-08-23 21:46 順⑦.z燃 阅读(565) 评论(0) 推荐(0) 编辑
摘要: 源代码 在 http://wiki.freepascal.org/paszlib页面中。uses zipper;procedure TForm1.Button5Click(Sender: TObject);var Zipper: TZipper; i:integer;begin //http://wiki.freepascal.org/paszlib try Zipper := TZipper.Create; Zipper.FileName := 'E:\20120411\zip\zip.zip'; Zipper.Entries.AddFileEntry('E:\201 阅读全文
posted @ 2012-08-23 13:10 順⑦.z燃 阅读(367) 评论(0) 推荐(0) 编辑
摘要: { No.1 判断逻辑类型 }var B: Boolean;beginB := Boolean(2); //这样只是为了调试//B := True;if B = True then ShowMessage('B = True'); //不建议//不安全///////if B then ShowMessage('B'); //建议//简短end;var B: Boolean;beginif Edit1.Text = '是' then //不建议//烦琐B := Trueelse B := False;///////B := Edit1.Text = 阅读全文
posted @ 2012-08-23 12:47 順⑦.z燃 阅读(190) 评论(0) 推荐(0) 编辑
摘要: procedure FileSearch(DirPath:AnsiString);var TarGetPath:string;{目标路径名} Sr:TsearchRec;begin TarGetPath:=ExtractFilePath(DirPath); {分解出目标路径名} if FindFirst(DirPath,faAnyfile,Sr)=0 then repeat if (Sr.name<>'.')and(Sr.name<>'..') then //排除父目录和本目录两个假文件 begin if ((FileGetAttr(Ta 阅读全文
posted @ 2012-08-23 10:36 順⑦.z燃 阅读(117) 评论(0) 推荐(0) 编辑