|
#931
|
|||
|
|||
|
I need an expert help here
.. i know that in msgboxes i cant insert a image, because of that, i make a custom form, and it work well, but i need to know how to to insert the "insert disc" message that i have in the original msgbox, into the custom form. This is the code: Quote:
|
| Sponsored Links |
|
#932
|
||||
|
||||
|
Quote:
|
|
#933
|
|||
|
|||
|
Thanks for your help altef 4.. i have the custom form, an ok and cancel button and a label. The code only ask for next disc, dont have browse dialog, i think the problem is in this part:
IDCANCEL then ISDoneError := True i dont know how to insert in the custom form code.. the complete code for the custom form is this: Quote:
Quote:
.
Last edited by Logrim; 17-02-2014 at 08:56. |
|
#934
|
||||
|
||||
|
Quote:
Code:
[Setup]
AppName=My Program
AppVersion=1.5
;AppVerName=My Program 1.5
AppPublisher=Winst@n, Inc.
DefaultDirName={pf}\My Program
DefaultGroupName=My Program
OutputDir=.
OutputBaseFilename=setup
Compression=lzma
SolidCompression=yes
[Languages]
Name: "rus"; MessagesFile: "compiler:Languages\Russian.isl"
[Files]
Source: {win}\help\*; DestDir: {app}\files1\; Flags: external recursesubdirs;
Source: {win}\help\*; DestDir: {app}\files2\; Flags: external recursesubdirs;
Source: {win}\help\*; DestDir: {app}\files3\; Flags: external recursesubdirs;
Source: {win}\help\*; DestDir: {app}\files4\; Flags: external recursesubdirs;
[code]
var
TNewDiskForm :TSetupForm;
DiskBitmapImage: TBitmapImage;
SelectDiskLabel,PathLabel: TLabel;
PathEdit: TEdit;
BrowseButton: TButton;
OKButton: TButton;
CancelButton: TButton;
Filename: String;
Path: String;
Dir: String;
ModalResult: Longint;
//path for searching file
function GetSanitizedPath: String;
begin
Result := Trim(PathEdit.Text);
end;
procedure CancelButtonClick(CurPageID: Integer; var Cancel, Confirm: Boolean);
begin
Cancel:=True;
Confirm:=False;
end;
//browse button procedure
procedure BrowseButtonClick(Sender: TObject);
begin
Dir := GetSanitizedPath;
if BrowseForFolder(SetupMessage (msgSelectDirectoryLabel), Dir, False) then
PathEdit.Text := Dir + '\';
TNewDiskForm.show;
end;
// close form (based on mrOK)
procedure FormCloseQuery(Sender: TObject; var CanClose: Boolean);
begin
Path := PathEdit.Text;
Filename:= ExpandConstant ('data_2.arc');
case TNewDiskForm.ModalResult of mrOK: begin
if (Path = '') or not FileExists(Path + Filename) then begin CanClose := false
MsgBox(FmtMessage(SetupMessage(msgFileNotInDir2), [Filename, Path]), mbError, MB_OK);
end;
end;
mrCancel:
begin
CanClose := True;
end;
end;
end;
// ask for next disk
procedure SelectDisk(const DiskNumber: Integer; const Filename, Path: String);
var ExitFlag:Boolean;
begin
repeat
TNewDiskForm:= CreateCustomForm();
TNewDiskForm.SetBounds(ScaleX(0), ScaleY(0), ScaleX(377), ScaleY(200));
TNewDiskForm.CenterInsideControl(WizardForm, False);
TNewDiskForm.Caption:=SetupMessage(msgChangeDiskTitle);
TNewDiskForm.Font.Color:= clWindowText
TNewDiskForm.Font.Height:= -11
TNewDiskForm.Font.Name:= 'MS Sans Serif'
TNewDiskForm.Font.Style:= []
TNewDiskForm.OnCloseQuery:=@FormCloseQuery;
SelectDiskLabel:=TLabel.Create(TNewDiskForm)
SelectDiskLabel.SetBounds(ScaleX(72),ScaleY(8), ScaleX(297), ScaleY(72));
SelectDiskLabel.AutoSize:=False
SelectDiskLabel.WordWrap:=True
SelectDiskLabel.Transparent:=True
SelectDiskLabel.Font.Color:=clBlack
SelectDiskLabel.Font.Size:=8
SelectDiskLabel.Caption:=FmtMessage(SetupMessage(msgSelectDiskLabel2), [IntToStr(DiskNumber)]);
SelectDiskLabel.Parent:=TNewDiskForm
SelectDiskLabel.ShowAccelChar:= False
PathEdit:=TEdit.Create(TNewDiskForm)
PathEdit.SetBounds(ScaleX(8), ScaleY(96), ScaleX(281), ScaleY(21));
PathEdit.TabOrder:=2
PathEdit.Text := ExpandConstant('{src}\');
PathEdit.Parent := TNewDiskForm;
PathLabel:= TLabel.Create(TNewDiskForm);
PathLabel.SetBounds(ScaleX(8),ScaleY(80), ScaleX(5), ScaleY(14));
PathLabel.Font.Color:=clBlack
PathLabel.FocusControl:= PathEdit
PathLabel.Caption := SetupMessage(msgPathLabel);
PathLabel.Parent:=TNewDiskForm
BrowseButton := TNewButton.Create(TNewDiskForm);
BrowseButton.SetBounds(ScaleX(296), ScaleY(95), ScaleX(73), ScaleY(23));
BrowseButton.Parent := TNewDiskForm;
BrowseButton.OnClick:=@BrowseButtonClick;
BrowseButton.Caption := SetupMessage(msgButtonBrowse);
CancelButton := TNewButton.Create(TNewDiskForm);
CancelButton.SetBounds(ScaleX(296), ScaleY(137), ScaleX(73), ScaleY(23));
CancelButton.ModalResult := mrCancel;
CancelButton.Parent := TNewDiskForm;
CancelButton.Caption := SetupMessage (msgButtonCancel);
OkButton := TNewButton.Create(TNewDiskForm);
OkButton.SetBounds(ScaleX(216), ScaleY(137), ScaleX(73), ScaleY(23));
OkButton.ModalResult := mrOk;
OkButton.Parent := TNewDiskForm;
OKButton.Caption := SetupMessage(msgButtonOK);
TNewDiskForm.ShowModal;
//close form (based on mrCancel)
case TNewDiskForm.ModalResult of mrCancel:
begin
MsgBox('file not found or you just want to exit, setup now finished',mbError, MB_OK);
TNewDiskForm.free;
ExitFlag:= ExitSetupMsgBox;
Case ExitFlag of True:WizardForm.Close;
False:SelectDisk (DiskNumber,Filename,Path);
True:TNewDiskForm.free;
end;
end;
end;
until ((TNewDiskForm.ModalResult=mrOk)or(TNewDiskForm.ModalResult=mrCancel));
end;
procedure CurStepChanged(CurStep: TSetupStep);
begin
// Unpacking form start disk № search path
// | |
if CurStep = ssInstall then SelectDisk (2, 'Filename','{src}');
end; // |
// searching file name
Last edited by altef_4; 17-02-2014 at 09:08. |
|
#935
|
||||
|
||||
|
I'm use this script and it's not working when extract with precomp anybody can help me?
|
|
#936
|
|||
|
|||
|
Hello
how to install a skin for the window to Uninstall InnoSetup. thank you |
|
#937
|
|||
|
|||
|
Hello everyone.
How can i group the tasks so i can check/uncheck them all at once in one click? |
|
#938
|
||||
|
||||
|
Quote:
I didnt check your script Quote:
Quote:
Then create a another check box and control them Else check help file for it Reply via mobile so cant do example
__________________
Glass BB | BlackBox v2 | Portable Installer Last edited by y_thelastknight; 18-02-2014 at 06:51. |
|
#939
|
|||
|
|||
|
#940
|
||||
|
||||
|
I have copied but it still does not work
|
|
#941
|
||||
|
||||
|
__________________
Glass BB | BlackBox v2 | Portable Installer |
|
#942
|
|||
|
|||
|
Quote:
|
|
#943
|
|||
|
|||
|
Thank for the change disc code Altef 4, work perfect.. this is how my change disk screen looks now thanks to you:
Nedd more fixers in the desing ![]()
|
| The Following User Says Thank You to Logrim For This Useful Post: | ||
y_thelastknight (18-02-2014) | ||
|
#944
|
||||
|
||||
|
Then i have to check on pc
![]() Right now i cant use pc
__________________
Glass BB | BlackBox v2 | Portable Installer |
| The Following User Says Thank You to y_thelastknight For This Useful Post: | ||
GloverK1911 (18-02-2014) | ||
|
#945
|
|||
|
|||
|
One rapid question.. I see in the forum (i dont remember what conversion has that) a custom procedure that add custom exit msgbox with image (that is the importat part)
, the procedure in cuestion was myexit.. anyone can help me to do a similar procedure? dont imagine how to do it.. thanks,, and sorry for so many questions.. its my first script with inno, and want to make a bit different.. i like to complicate my life, lol ![]() P.D. i think, the conversion is made by fabio.. dont remember. Edit: I found the answer for myself.. Thanks to Razor, y_thelastknight and Altef i'm learning a lot. In two days i post a preview, i hope you like it, thanks all three. Edit2.. Found a new problem that i dont know how to resolve,, sorry.. the custom exit button work like a charm in normal exit, but in change disk exit, the button appears twice. One normal exit msgbox and one the custom exit. I know whats is the problem, but i dont know how to change things for it works.. I need help,,, again.. sorry.. The problem is here, (ExitFlag:= ExitSetupMsgBox; //this is normal exit message) this is the final part of change disk form: Quote:
Quote:
Quote:
Last edited by Logrim; 19-02-2014 at 05:37. |
| The Following User Says Thank You to Logrim For This Useful Post: | ||
oltjon (19-02-2014) | ||
![]() |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| INNO TROUBLESHOOT - Tutorials and Answers about INNO Setup | REV0 | Conversion Tutorials | 129 | 21-05-2021 05:51 |
| INNO TUTORIAL - Using Unicode and ANSI Versions of INNO Setup | REV0 | Conversion Tutorials | 51 | 26-03-2015 06:57 |
| Frequently Asked Questions | Joe Forster/STA | PC Games - Frequently Asked Questions | 0 | 29-11-2005 09:48 |