How to creat AboutDialog like AboutDialog of Explorer?None can help me??I forget where i saw it.
I only remember the API function that one of parameters is a string.
The string be connected two parts with '#', one is the title, another is a string under the copyright string.like this:
--------------------------------------------
|About Windows (part1) |
|------------------------------------------|
| Microsoft Windows |
| Version ..... |
| CopyRight..... |
| (part2) |
| |
| This product is licensed to |
| ..... |
| ..... |
| --------------------------- |
| Pysical memory .... |
| OK |
--------------------------------------------Only a function!!! anyone can help me??
I only remember the API function that one of parameters is a string.
The string be connected two parts with '#', one is the title, another is a string under the copyright string.like this:
--------------------------------------------
|About Windows (part1) |
|------------------------------------------|
| Microsoft Windows |
| Version ..... |
| CopyRight..... |
| (part2) |
| |
| This product is licensed to |
| ..... |
| ..... |
| --------------------------- |
| Pysical memory .... |
| OK |
--------------------------------------------Only a function!!! anyone can help me??
解决方案 »
- 郁闷,做好的程序不能发布
- 打印机字体大小设置
- 下载installshield DELPHI7用的 给 个 准确点的网址 查的 那些都打不开
- dbgrid$$$$$$
- 超难的问题:高手请进! 从delphi7如何在excel中导出一列斜线和对应交叉的反斜线,紧急求助
- DBGrid怎么正常显示数据库中编码过的数据
- OleVariant数据的读写?
- 从哪里可以下载安装制作软件InstallShield和Wise?
- 有关Memo控件的问题
- 各位大虾,小弟想做一个局域网文件传输软件,但不知从何下手,望各路高手指点,给出代码!up有分,不断加分。
- 调查:技术资料
- delphi同sql server的SQL语句结合问题!(总分不愁,最高500分)
我在
http://community.activepower.net/model/home_model/2/frame.asp?main_frame=main&community_name=星艺星空
上传了,大家不要向我要了
Code:
GetOpenFileNametype
TLPOFNHOOKPROC=function(h:hwnd;uMsg:UINT;wp:wparam;lp:lParam):integer;
type
TOpenInfo=packed record
lStructSize:dword;
hwndOwner:hwnd;
hInstance:Hwnd;
lpstrFilter:LPCTSTR;
lpstrCustomFilter:LPTSTR;
nMaxCustFilter:dword;
nFilterIndex:dword;
lpstrFile:lptstr; //该参数使用来存放对话框返回的文件名(包含路径)的,得是一个至少256个长的Pchar
nMaxFile:dword; //该参数使用来指定info.lpstrFile长度以及存放对话框返回的文件名的长度的
lpstrFileTitle:lptstr;
nMaxFileTitle:dword;
lpstrInitialDir:lpctstr;
lpstrTitle:lpctstr;
Flags:dword;
nFileOffset:word;
nFileExtension:word;
lpstrDefExt:lpctstr;
lCustData:Lparam;
lpfnHook:TLPOFNHOOKPROC;
lpTemplateName:lpctstr;
pvReserved:integer;
dwReserved:dword;
FlagsEx:dword;
end;function GetOpenFileName(var info:TOpenInfo):boolean;stdcall; external 'comdlg32.dll' name 'GetOpenFileNameA';procedure TForm1.Button1Click(Sender: TObject);
var
info:TOpenInfo;
lpstrFile:array[0..1000] of char;
lpstrFileTitle:array[0..1000] of char;
lpstrFilter:array[0..50] of char;
S:String;
begin
FillChar(lpstrFile,SizeOf(lpstrFile),0);
FillChar(lpstrFileTitle,SizeOf(lpstrFileTitle),0);
FillChar(lpstrFilter,SizeOf(lpstrFilter),0);
S:='文本文件';
Move(S[1],lpstrFilter,Length(S));
S:='*.TXT';
Move(S[1],lpstrFilter[9],Length(S)); info.lStructSize:=sizeof(info);
info.hWndOwner:=handle;
info.hInstance:=hinstance;
info.lpstrFilter:=lpstrFilter;
info.lpstrCustomFilter:=nil;
info.nMaxCustFilter:=0;
info.nFilterIndex:=1;
info.lpstrFile:=lpstrFile;
info.nMaxFile:=SizeOf(lpstrFile);
info.lpstrFileTitle:=lpstrFileTitle;
info.nMaxFileTitle:=SizeOf(lpstrFileTitle);
info.lpstrInitialDir:='c:\';
info.lpstrTitle:='Open Test';
info.Flags:=0;//OFN_ENABLESIZING+OFN_EXPLORER;
info.nFileOffset:=0;
info.nFileExtension:=0;
info.lpstrDefExt:='txt';
info.lCustData:=0;
info.lpfnHook:=nil;
info.lpTemplateName:='';
info.pvReserved:=0;
info.dwReserved:=0;
info.FlagsEx:=0;
try
if GetOpenFileName(info) then
ShowMessage(info.lpstrFile);
except
caption:=SysErrorMessage(getlasterror);
end;
end;