http://www.cnblogs.com/awei0611/archive/2010/06/09.html 1 、如何让协议许可页面默认选中我同意按钮 [delphi] view plaincopyprint? [code] procedure InitializeWizard(); begin WizardForm . LICENSEACCEPTEDRADIO . Checked := true ; end ; [code]pro
http://www.cnblogs.com/awei0611/archive/2010/06/09.html
1 、如何让协议许可页面默认选中我同意按钮
[delphi] view plaincopyprint?
- [code]
- procedure InitializeWizard();
- begin
- WizardForm.LICENSEACCEPTEDRADIO.Checked := true;
- end;
[code] procedure InitializeWizard(); begin WizardForm.LICENSEACCEPTEDRADIO.Checked := true; end;
2、自定义安装程序右上角图片大小
[delphi] view plaincopyprint?
- [code]
- procedure InitializeWizard();
- begin
- WizardForm.WizardSmallBitmapImage.width:=150; //设置页眉图片的大小
- WizardForm.WizardSmallBitmapImage.left:=WizardForm.width-150; //设置左边页眉留出的空隙
- WizardForm.PAGENAMELABEL.width:=0; //设置标题文字显示的大小
- WizardForm.PAGEDESCRIPTIONLABEL.width:=0; //设置标题文字显示的大小
- end;
[code] procedure InitializeWizard(); begin WizardForm.WizardSmallBitmapImage.width:=150; //设置页眉图片的大小 WizardForm.WizardSmallBitmapImage.left:=WizardForm.width-150; //设置左边页眉留出的空隙 WizardForm.PAGENAMELABEL.width:=0; //设置标题文字显示的大小 WizardForm.PAGEDESCRIPTIONLABEL.width:=0; //设置标题文字显示的大小 end;
或者
//自定义安装向导小图片
[delphi] view plaincopyprint?
- [code]
- procedure InitializeWizard();
- begin
- Wizardform.WizardSmallBitmapImage.left:= WizardForm.width-164; //自定义安装向导小图片显示位置
- WizardForm.WizardSmallBitmapImage.width:=164; //自定义安装向导小图片宽度
- Wizardform.PageNameLabel.width:= 495 - 164 -36; //这儿必须定义,数值根据图片宽度更改,显示软件名称的位置
- Wizardform.PageDescriptionLabel.width:= 495 - 164 -42; //显示页面信息的位置
- end;
[code] procedure InitializeWizard(); begin Wizardform.WizardSmallBitmapImage.left:= WizardForm.width-164; //自定义安装向导小图片显示位置 WizardForm.WizardSmallBitmapImage.width:=164; //自定义安装向导小图片宽度 Wizardform.PageNameLabel.width:= 495 - 164 -36; //这儿必须定义,数值根据图片宽度更改,显示软件名称的位置 Wizardform.PageDescriptionLabel.width:= 495 - 164 -42; //显示页面信息的位置 end;
3、自定义BeveledLabel显示代码
[delphi] view plaincopyprint?
- [code]
- procedure InitializeWizard();
- begin
- WizardForm.BeveledLabel.Enabled:=true; //允许显示
- WizardForm.BeveledLabel.Font.Color:=$00058451;; //显示颜色
- WizardForm.BeveledLabel.Font.Style := WizardForm.BeveledLabel.Font.Style + [fsBold]; //显示字体
- WizardForm.BeveledLabel.Left:=5; //显示位置
- end;
[code] procedure InitializeWizard(); begin WizardForm.BeveledLabel.Enabled:=true; //允许显示 WizardForm.BeveledLabel.Font.Color:=$00058451;; //显示颜色 WizardForm.BeveledLabel.Font.Style := WizardForm.BeveledLabel.Font.Style + [fsBold]; //显示字体 WizardForm.BeveledLabel.Left:=5; //显示位置 end;
4、自定义安装向导图片
[delphi] view plaincopyprint?
- [code]
- procedure InitializeWizard();
- begin
- Wizardform.WELCOMELABEL1.left:= 18; //自定义欢迎页面标题1显示位置
- Wizardform.WELCOMELABEL2.left:= 18; //自定义欢迎页面标题2显示位置
- Wizardform.WizardBitmapImage.left:= WizardForm.width-164//自定义安装向导图片显示位置(显示大小,此处为居右显示)
- end;
[code] procedure InitializeWizard(); begin Wizardform.WELCOMELABEL1.left:= 18; //自定义欢迎页面标题1显示位置 Wizardform.WELCOMELABEL2.left:= 18; //自定义欢迎页面标题2显示位置 Wizardform.WizardBitmapImage.left:= WizardForm.width-164 //自定义安装向导图片显示位置(显示大小,此处为居右显示) end;
5、显示出组件选择框 [Types]
[delphi] view plaincopyprint?
- Name: full; Description: 推荐
- Name: default; Description: 典型
- Name: custom; Description: 自定义; Flags: iscustom
- ;告诉安装程序这个类型是自定义类型。必须定义iscustom这个参数,才能显示出组件选择框
Name: full; Description: 推荐 Name: default; Description: 典型 Name: custom; Description: 自定义; Flags: iscustom ;告诉安装程序这个类型是自定义类型。必须定义iscustom这个参数,才能显示出组件选择框
6、定义[Messages]的颜色
[delphi] view plaincopyprint?
- [code]
- procedure InitializeWizard();
- begin
- WizardForm.BeveledLabel.Enabled:= True;
- WizardForm.BeveledLabel.Font.Color:= clblue;
- end;
[code] procedure InitializeWizard(); begin WizardForm.BeveledLabel.Enabled:= True; WizardForm.BeveledLabel.Font.Color:= clblue; end;
7、不显示一些特定的安装界面
[delphi] view plaincopyprint?
- [code]
- function ShouldSkipPage(PageID: Integer): Boolean;
- begin
- if PageID=wpReady then
- result := true;
- end;
- (*
- wpReady 是准备安装界面
- PageID查询 INNO帮助中的 Pascal 脚本: 事件函数常量
- 预定义向导页 CurPageID 值
- wpWelcome, wpLicense, wpPassword, wpInfoBefore, wpUserInfo, wpSelectDir, wpSelectComponents, wpSelectProgramGroup, wpSelectTasks, wpReady, wpPreparing, wpInstalling, wpInfoAfter, wpFinished
[code] function ShouldSkipPage(PageID: Integer): Boolean; begin if PageID=wpReady then result := true; end; (* wpReady 是准备安装界面 PageID查询 INNO帮助中的 Pascal 脚本: 事件函数常量 预定义向导页 CurPageID 值 wpWelcome, wpLicense, wpPassword, wpInfoBefore, wpUserInfo, wpSelectDir, wpSelectComponents, wpSelectProgramGroup, wpSelectTasks, wpReady, wpPreparing, wpInstalling, wpInfoAfter, wpFinished
8、换行符号
在 [Messages] 换行符号为%n
在 MsgBox 中换行符号为 #13#10 //#13 为回车字符
9、颜色代码
(1)一个值形如 $bbggrr, 这里的 rr, gg 和 bb 指定了两位的亮度值(以十六进制表示)分别为红色,绿色和蓝色。
(2)预定义的颜色名称:
clBlack(黑色),clMaroon(暗红),clGreen(绿色),clOlive(橄榄绿),
clNavy(深蓝),clPurple(紫色),clTeal(深青),clGray(灰色),
clSilver(浅灰),clRed(红色),clLime(浅绿),clYellow(黄色),
clBlue(蓝色),clFuchsia(紫红),clAqua(青绿),clWhite(白色)。
10、inno代码注释符号
; 实例 —— ; 分号
// 实例 —— // 双斜杠 多用在code段
{ } 实例 —— {大括号 多用在code段}
注释符号均在英文输入法状态下输入
11、在运行卸载程序前显示弹出式消息
[delphi] view plaincopyprint?
- [code]
- function InitializeUninstall(): Boolean;
- begin
- if MsgBox('', mbConfirmation, MB_YESNO) = IDYES then
- result:=true
- else
- result:=false;
- end;
[code] function InitializeUninstall(): Boolean; begin if MsgBox('', mbConfirmation, MB_YESNO) = IDYES then result:=true else result:=false; end;
12、安装、卸载时判断是否程序正在运行,卸载完成时自动打开网页
[delphi] view plaincopyprint?
- [code]
- var
- ErrorCode: Integer;
- IsRunning: Integer;
- // 安装时判断客户端是否正在运行
- function InitializeSetup(): Boolean;
- begin
- Result :=true; //安装程序继续
- IsRunning:=FindWindowByWindowName('东方宽频网络电视');
- while IsRunning0do
- begin
- if Msgbox('安装程序检测到客户端正在运行。' #13#13'您必须先关闭它然后单击“是”继续安装,或按“否”退出!', mbConfirmation, MB_YESNO) = idNO then
- begin
- Result :=false; //安装程序退出
- IsRunning :=0;
- endelsebegin
- Result :=true; //安装程序继续
- IsRunning:=FindWindowByWindowName('东方宽频网络电视');
- end;
- end;
- end;
- // 卸载时判断客户端是否正在运行
- function InitializeUninstall(): Boolean;
- begin
- Result :=true; //安装程序继续
- IsRunning:=FindWindowByWindowName('东方宽频网络电视');
- while IsRunning0do
- begin
- if Msgbox('安装程序检测到客户端正在运行。' #13#13'您必须先关闭它然后单击“是”继续安装,或按“否”退出!', mbConfirmation, MB_YESNO) = idNO then
- begin
- Result :=false; //安装程序退出
- IsRunning :=0;
- endelsebegin
- Result :=true; //安装程序继续
- IsRunning:=FindWindowByWindowName('东方宽频网络电视');
- end;
- end;
- end;
- procedure CurUninstallStepChanged(CurUninstallStep: TUninstallStep);
- begin
- case CurUninstallStep of
- usUninstall:
- begin// 开始卸载
- end;
- usPostUninstall:
- begin// 卸载完成
- // MsgBox('CurUninstallStepChanged:' #13#13 'Uninstall just finished.', mbInformation, MB_OK);
- // ...insert code to perform post-uninstall tasks here...
- ShellExec('open', 'http://www.dreams8.com', '', '', SW_SHOWNORMAL, ewNoWait, ErrorCode);
- end;
- end;
- end;
[code] var ErrorCode: Integer; IsRunning: Integer; // 安装时判断客户端是否正在运行 function InitializeSetup(): Boolean; begin Result :=true; //安装程序继续 IsRunning:=FindWindowByWindowName('东方宽频网络电视'); while IsRunning0 do begin if Msgbox('安装程序检测到客户端正在运行。' #13#13 '您必须先关闭它然后单击“是”继续安装,或按“否”退出!', mbConfirmation, MB_YESNO) = idNO then begin Result :=false; //安装程序退出 IsRunning :=0; end else begin Result :=true; //安装程序继续 IsRunning:=FindWindowByWindowName('东方宽频网络电视'); end; end; end; // 卸载时判断客户端是否正在运行 function InitializeUninstall(): Boolean; begin Result :=true; //安装程序继续 IsRunning:=FindWindowByWindowName('东方宽频网络电视'); while IsRunning0 do begin if Msgbox('安装程序检测到客户端正在运行。' #13#13 '您必须先关闭它然后单击“是”继续安装,或按“否”退出!', mbConfirmation, MB_YESNO) = idNO then begin Result :=false; //安装程序退出 IsRunning :=0; end else begin Result :=true; //安装程序继续 IsRunning:=FindWindowByWindowName('东方宽频网络电视'); end; end; end; procedure CurUninstallStepChanged(CurUninstallStep: TUninstallStep); begin case CurUninstallStep of usUninstall: begin // 开始卸载 end; usPostUninstall: begin // 卸载完成 // MsgBox('CurUninstallStepChanged:' #13#13 'Uninstall just finished.', mbInformation, MB_OK); // ...insert code to perform post-uninstall tasks here... ShellExec('open', 'http://www.dreams8.com', '', '', SW_SHOWNORMAL, ewNoWait, ErrorCode); end; end; end;
13、 删除文件和删除文件夹
[delphi] view plaincopyprint?
- //删除文件 用 DeleteFile 只能删除一个文件,不能使用通配符来删除多个文件
- DeleteFile(ExpandConstant('{app}\abc.exe'));
- //删除所有文件及文件夹
- DelTree(ExpandConstant('{app}'), True, True, False);
//删除文件 用 DeleteFile 只能删除一个文件,不能使用通配符来删除多个文件 DeleteFile(ExpandConstant('{app}\abc.exe')); //删除所有文件及文件夹 DelTree(ExpandConstant('{app}'), True, True, False);
14、BorderStyle
TFormBorderStyle = (bsNone, bsSingle, bsSizeable, bsDialog, bsToolWindow, bsSizeToolWin);
无边界式(bsNone) ,单边固定式(bsSingle),双边可变式(bsSizeable),对话框式(bsDialog)
15、if else
[delphi] view plaincopyprint?
- function NextButtonClick(CurPageID: Integer): Boolean;
- var
- ResultCode: Integer;
- begin
- Result := True;
- if (CurPageID = wpSelectDir) then
- begin
- MsgBox('AAAA', mbInformation, MB_OK);
- end
- else
- begin
- MsgBox('BBBB', mbInformation, MB_OK);
- end;
- end;
function NextButtonClick(CurPageID: Integer): Boolean; var ResultCode: Integer; begin Result := True; if (CurPageID = wpSelectDir) then begin MsgBox('AAAA', mbInformation, MB_OK); end else begin MsgBox('BBBB', mbInformation, MB_OK); end; end;
16、安装结束界面增加“设为首页”选项
[delphi] view plaincopyprint?
- [Tasks]
- Name: changestartpage; Description: "设置vistaqq为默认主页"
- [Registry]
- Root: HKCU; Subkey: "Software\Microsoft\Internet Explorer\Main"; ValueType: string; ValueName: "Start Page"; ValueData: "http://www.vistaqq.com"; tasks: changestartpage
[Tasks] Name: changestartpage; Description: "设置vistaqq为默认主页" [Registry] Root: HKCU; Subkey: "Software\Microsoft\Internet Explorer\Main"; ValueType: string; ValueName: "Start Page"; ValueData: "http://www.vistaqq.com"; tasks: changestartpage
17、添加“关于”和网站链接按钮
[delphi] view plaincopyprint?
- [Code]
- procedure URLLabelOnClick(Sender: TObject);
- var
- ErrorCode: Integer;
- begin
- ShellExec('open', 'http://www.vistaqq.com', '', '', SW_SHOWNORMAL, ewNoWait, ErrorCode);
- end;
- procedure AboutButtonOnClick(Sender: TObject);
- begin
- MsgBox(#13'Vista 状态条风格盘符' #13 #13'本软件由jinn制作,希望各位登陆中天VIP工作室!' #13#13, mbInformation, MB_OK);
- end;
- var
- AboutButton, CancelButton: TButton;
- URLLabel: TNewStaticText;
- procedure InitializeWizard();
- begin
- { Create the pages }
- WizardForm.PAGENAMELABEL.Font.Color:= clred;
- WizardForm.PAGEDESCRIPTIONLABEL.Font.Color:= clBlue;
- WizardForm.WELCOMELABEL1.Font.Color:= clGreen;
- WizardForm.WELCOMELABEL2.Font.Color:= clblack;
- CancelButton := WizardForm.CancelButton;
- AboutButton := TButton.Create(WizardForm);
- AboutButton.Left := WizardForm.ClientWidth - CancelButton.Left - CancelButton.Width;
- AboutButton.Top := CancelButton.Top;
- AboutButton.Width := CancelButton.Width;
- AboutButton.Height := CancelButton.Height;
- AboutButton.Caption := '&About';
- AboutButton.OnClick := @AboutButtonOnClick;
- AboutButton.Parent := WizardForm;
- URLLabel := TNewStaticText.Create(WizardForm);
- URLLabel.Caption := '中天VIP工作室';
- URLLabel.Cursor := crHand;
- URLLabel.OnClick := @URLLabelOnClick;
- URLLabel.Parent := WizardForm;
- { Alter Font *after* setting Parent so the correct defaults are inherited first }
- URLLabel.Font.Style := URLLabel.Font.Style + [fsUnderline];
- URLLabel.Font.Color := clBlue;
- URLLabel.Top := AboutButton.Top + AboutButton.Height - URLLabel.Height - 2;
- URLLabel.Left := AboutButton.Left + AboutButton.Width + ScaleX(20);
- end;
18、去掉安装程序左上角“关于安装程序”的代码
[delphi] view plaincopyprint?
- procedure InitializeWizard();
- begin
- WizardForm.BorderIcons:= [biMinimize];
- end;
- procedure CurPageChanged(CurPage: Integer);
- begin
- if CurPage=wpWelcome then
- WizardForm.BorderIcons:= [biSystemMenu, biMinimize];
- end;
- 或者
- procedure InitializeWizard();
- begin
- WizardForm.BORDERICONS := [biHelp, biSystemMenu, biMinimize];
- end;
procedure InitializeWizard(); begin WizardForm.BorderIcons:= [biMinimize]; end; procedure CurPageChanged(CurPage: Integer); begin if CurPage=wpWelcome then WizardForm.BorderIcons:= [biSystemMenu, biMinimize]; end; 或者 procedure InitializeWizard(); begin WizardForm.BORDERICONS := [biHelp, biSystemMenu, biMinimize]; end;
19、自定义BeveledLabel文字
[Messages]
BeveledLabel=中天VIP工作室
20、自定义安装程序界面左上角“安装”文字
[message]
SetupAppTitle=需要的字
SetupWindowTitle=需要的字
21、自定义安装程序版本号
VersionInfoVersion=1.1
VersionInfoTextVersion=1.1

MySQL 성능을 효과적으로 모니터링하는 방법은 무엇입니까? Mysqladmin, Showglobalstatus, Perconamonitoring and Management (PMM) 및 MySQL Enterprisemonitor와 같은 도구를 사용하십시오. 1. MySQLADMIN을 사용하여 연결 수를보십시오. 2. showglobalstatus를 사용하여 쿼리 번호를보십시오. 3.pmm은 자세한 성능 데이터 및 그래픽 인터페이스를 제공합니다. 4. MySQLENTERPRISOMITOR는 풍부한 모니터링 기능 및 경보 메커니즘을 제공합니다.

MySQL과 SqlServer의 차이점은 1) MySQL은 오픈 소스이며 웹 및 임베디드 시스템에 적합합니다. 2) SQLServer는 Microsoft의 상용 제품이며 엔터프라이즈 수준 애플리케이션에 적합합니다. 스토리지 엔진의 두 가지, 성능 최적화 및 응용 시나리오에는 상당한 차이가 있습니다. 선택할 때는 프로젝트 규모와 향후 확장 성을 고려해야합니다.

고 가용성, 고급 보안 및 우수한 통합이 필요한 엔터프라이즈 수준의 응용 프로그램 시나리오에서는 MySQL 대신 SQLServer를 선택해야합니다. 1) SQLServer는 고 가용성 및 고급 보안과 같은 엔터프라이즈 수준의 기능을 제공합니다. 2) VisualStudio 및 Powerbi와 같은 Microsoft Ecosystems와 밀접하게 통합되어 있습니다. 3) SQLSERVER는 성능 최적화에서 우수한 성능을 발휘하며 메모리 최적화 된 테이블 및 열 스토리지 인덱스를 지원합니다.

mysqlmanagesCharactersetsandcollationsUtf-8AsthedEfault, confonfigurationAtdatabase, 테이블 및 columnlevels, andcolumnlevels, andcolumnlevels, andcolumnlevels, 1) setDefaultCharactersetandcollationforadatabase.2) secigurecharactersetandcollation

MySQL 트리거는 특정 데이터 작업이 수행 될 때 일련의 작업을 수행하는 데 사용되는 테이블과 관련된 자동 실행 된 저장 프로 시저입니다. 1) 트리거 정의 및 기능 : 데이터 검증, 로깅 등에 사용됩니다. 2) 작업 원칙 : 전후에 나누어지고 행 수준 트리거링을 지원합니다. 3) 사용의 예 : 급여 변경을 기록하거나 재고를 업데이트하는 데 사용할 수 있습니다. 4) 디버깅 기술 : ShowTriggers 및 ShowCreateTrigger 명령을 사용하십시오. 5) 성능 최적화 : 복잡한 작업을 피하고 인덱스 사용 및 거래 관리.

MySQL에서 사용자 계정을 작성하고 관리하는 단계는 다음과 같습니다. 1. 사용자 만들기 : CreateUser'Newuser '@'localhost'Identifiedby'Password '; 2. 권한 할당 : GrantSelect 사용, 삽입, UpdateOnmyDatabase.to'newuser'@'localhost '; 3. 권한 오류 수정 : Revokeallprivilegesonmydatabase.from'Newuser'@'localhost '; 그런 다음 권한을 재 할당합니다. 4. 최적화 권한 : showgra를 사용하십시오

MySQL은 빠른 개발 및 중소형 응용 프로그램에 적합한 반면 Oracle은 대기업 및 고 가용성 요구에 적합합니다. 1) MySQL은 오픈 소스이며 사용하기 쉬우 며 웹 응용 프로그램 및 중소 기업에 적합합니다. 2) Oracle은 강력하고 대기업 및 정부 기관에 적합합니다. 3) MySQL은 다양한 스토리지 엔진을 지원하며 Oracle은 풍부한 엔터프라이즈 수준의 기능을 제공합니다.

다른 관계형 데이터베이스와 비교하여 MySQL의 단점에는 다음이 포함됩니다. 1. 성능 문제 : 대규모 데이터를 처리 할 때 병목 현상을 만날 수 있으며 PostgreSQL은 복잡한 쿼리 및 빅 데이터 처리에서 더 잘 수행됩니다. 2. 확장 성 : 수평 스케일링 능력은 Google 스패너 및 Amazon Aurora만큼 좋지 않습니다. 3. 기능 제한 : 고급 기능에서 PostgreSQL 및 Oracle만큼 좋지 않으면 일부 기능에는 더 많은 사용자 정의 코드 및 유지 관리가 필요합니다.


핫 AI 도구

Undresser.AI Undress
사실적인 누드 사진을 만들기 위한 AI 기반 앱

AI Clothes Remover
사진에서 옷을 제거하는 온라인 AI 도구입니다.

Undress AI Tool
무료로 이미지를 벗다

Clothoff.io
AI 옷 제거제

Video Face Swap
완전히 무료인 AI 얼굴 교환 도구를 사용하여 모든 비디오의 얼굴을 쉽게 바꾸세요!

인기 기사

뜨거운 도구

ZendStudio 13.5.1 맥
강력한 PHP 통합 개발 환경

Eclipse용 SAP NetWeaver 서버 어댑터
Eclipse를 SAP NetWeaver 애플리케이션 서버와 통합합니다.

DVWA
DVWA(Damn Vulnerable Web App)는 매우 취약한 PHP/MySQL 웹 애플리케이션입니다. 주요 목표는 보안 전문가가 법적 환경에서 자신의 기술과 도구를 테스트하고, 웹 개발자가 웹 응용 프로그램 보안 프로세스를 더 잘 이해할 수 있도록 돕고, 교사/학생이 교실 환경 웹 응용 프로그램에서 가르치고 배울 수 있도록 돕는 것입니다. 보안. DVWA의 목표는 다양한 난이도의 간단하고 간단한 인터페이스를 통해 가장 일반적인 웹 취약점 중 일부를 연습하는 것입니다. 이 소프트웨어는

VSCode Windows 64비트 다운로드
Microsoft에서 출시한 강력한 무료 IDE 편집기

SublimeText3 Mac 버전
신 수준의 코드 편집 소프트웨어(SublimeText3)
