随笔分类 -  Delphi

关于delphi的笔记
摘要:操作系统: win95 编程工具: vb6.0 问题: 请教 SendMessage() API 函数如何使用? 回答: 以下内容节选自我的书《Visual Basic编程晋级:ActiveX控件》: 要发送消息,我们就需要使用API函数SendMessage。这个函数的定义如下: Declare Function SendMessage Lib "user32" _ Alias "SendMessageA" (ByVal hwnd As Long, _ ByVal wMsg As Long, ByVal wParam As ... 阅读全文
posted @ 2012-11-07 21:06 斗天! 阅读(476) 评论(0) 推荐(0)
摘要:Delphi中取得和设置硬盘上文件的创建日期、修改日期、访问日期、文件属性function FileAge(const FileName: string): Integer; $[SysUtils.pas 功能 返回文件创建的时间 说明 文件不存在则返回-1 参考 function Windows.FindFirstFile 例子 ///////Begin FileAge,DateTimeToStr,FileDateToDateTime procedure TForm1.Button1Click(Sender: TObject); begin SpinEdit1.Value := FileAg 阅读全文
posted @ 2012-10-29 21:34 斗天! 阅读(896) 评论(0) 推荐(0)
摘要:function geticon(path:string):Integer;vari:Integer;extion:string;strlist:TStrings;begin i:=path.LastIndexOf('.'); extion:=path.Substring(i); extion:=extion.ToLower; strlist:=TStringList.Create; strlist.Add('.txt'); strlist.Add('.zip'); strlist.Add('.rar'); strlist.Add 阅读全文
posted @ 2012-10-25 02:09 斗天! 阅读(541) 评论(0) 推荐(0)
摘要:正确的方法是 1. 进入 C:\Program Files\Borland 2. 鼠标放到 delphi7目录上面 3. 右键菜单----属性----安全----点Users----编辑----点Users----所有能勾的权限勾上 4. 点 应用 5. 点 确定 打开delphi7或者要打开Project1.dpr均必须用鼠标右键菜单中的"以管理员身份运行"转自:<a href='http://sws.yuloo.com/'>国际商务师考试网</a> 阅读全文
posted @ 2012-10-25 02:06 斗天! 阅读(276) 评论(0) 推荐(0)
摘要:unit Unit1;interfaceuses Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms, Dialogs, StdCtrls;type TForm1 = class(TForm) btn1: TButton; lst_file: TListBox; lst_path: TListBox; lbl1: TLabel; lbl2: TLabel; procedure btn1Click(Sender: TObject); private { Private declarations } { 阅读全文
posted @ 2012-09-27 22:04 斗天! 阅读(362) 评论(0) 推荐(0)