1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156
| unit Unit1;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, StdCtrls, ShellAPI;
type
TForm1 = class(TForm)
AUTO: TButton;
Label1: TLabel;
GroupBox1: TGroupBox;
Portable: TRadioButton;
Bureau: TRadioButton;
GroupBox2: TGroupBox;
Seven: TRadioButton;
XP: TRadioButton;
ListBox1: TListBox;
ENTER: TButton;
ComboBox1: TComboBox;
procedure AUTOClick(Sender: TObject);
procedure PortableClick(Sender: TObject);
procedure SevenClick(Sender: TObject);
procedure BureauClick(Sender: TObject);
procedure XPClick(Sender: TObject);
procedure ENTERClick(Sender: TObject);
procedure ComboBox1Change(Sender: TObject);
procedure ListBox1Click(Sender: TObject);
private
{ Déclarations privées }
public
{ Déclarations publiques }
end;
var
Form1: TForm1;
port,sev,bur,wxp:boolean;
teamviewer,Dropbox,Msql,ixxat,MPLAB,FTDI,IFM,VALENCE,VENSCO,InitMysql : integer;
manu_teamviewer,manu_Dropbox,manu_Msql,manu_ixxat,manu_MPLAB,manu_FTDI,manu_IFM,manu_VALENCE,manu_VENSCO,manu_InitMysql : integer;
niv:integer;
implementation
{$R *.dfm}
procedure TForm1.AUTOClick(Sender: TObject);
begin
if (Dropbox=1) then ShellExecute(Handle,'open','\\pvifiler1.pvi.local\Commun\BEE\Install_SAV\Dropbox.exe',nil,Nil,SW_SHOWDEFAULT);
if (Msql=1) then ShellExecute(Handle,'open','\\pvifiler1.pvi.local\Commun\BEE\Install_SAV\mysql-5.5.1-m2-win32.msi',nil,Nil,SW_SHOWDEFAULT);
if ((ixxat=1) and sev ) then ShellExecute(Handle,'open','\\pvifiler1.pvi.local\Commun\BEE\Install_SAV\VCI_2_18_4_2308.exe',nil,Nil,SW_SHOWDEFAULT);
if (((ixxat=1) and wxp ) or (manu_ixxat=1) ) then ShellExecute(Handle,'open','\\pvifiler1.pvi.local\Commun\BEE\Install_SAV\vci216+sp2.exe',nil,Nil,SW_SHOWDEFAULT);
if (MPLAB=1) then ShellExecute(Handle,'open','\\pvifiler1.pvi.local\Commun\BEE\Install_SAV\MPLAB_IDE_v8_63\setup.exe',nil,Nil,SW_SHOWDEFAULT);
if (FTDI=1) then ShellExecute(Handle,'open','\\pvifiler1.pvi.local\Commun\BEE\Install_SAV\CDM_2.02.04.exe',nil,Nil,SW_SHOWDEFAULT);
if (teamviewer=1) then ShellExecute(Handle,'open','\\pvifiler1.pvi.local\Commun\BEE\Install_SAV\TeamViewer_Setup_fr-wv.exe',nil,Nil,SW_SHOWDEFAULT);
if (IFM=1) then ShellExecute(Handle,'open','\\pvifiler1.pvi.local\Commun\BEE\Install_SAV\Maintenance\setup.exe',nil,Nil,SW_SHOWDEFAULT);
if (VALENCE=1) then ShellExecute(Handle,'open','\\pvifiler1.pvi.local\Commun\BEE\Install_SAV\Module_Diag_XP_12.9.msi',nil,Nil,SW_SHOWDEFAULT);
if (VENSCO=1) then ShellExecute(Handle,'open','\\pvifiler1.pvi.local\Commun\BEE\Install_SAV\Vansco_USB_DLA_Driver_V1.7.exe',nil,Nil,SW_SHOWDEFAULT);
if (InitMysql=1) then ShellExecute(Handle,'open','\\pvifiler1.pvi.local\Commun\BEE\Install_SAV\Vansco_USB_DLA_Driver_V1.7.exe',nil,Nil,SW_SHOWDEFAULT);
end;
procedure TForm1.PortableClick(Sender: TObject);
begin
port:=Portable.Checked;
bur:=false;
end;
procedure TForm1.SevenClick(Sender: TObject);
begin
sev:=Seven.Checked;
wxp:=false;
end;
procedure TForm1.BureauClick(Sender: TObject);
begin
bur:=Bureau.checked;
port:=false;
end;
procedure TForm1.XPClick(Sender: TObject);
begin
wxp:=xp.checked;
sev:=false;
end;
procedure TForm1.ComboBox1Change(Sender: TObject);
begin
niv:=StrToInt(combobox1.Text);
end;
procedure select();
begin
if ((port or bur) and (niv>=0) ) then Dropbox:=1 else Dropbox:=0;
if (port and (niv>=0) ) then Msql:=1 else Msql:=0;
if (port and (niv>=2) ) then ixxat:=1 else ixxat:=0;
if (port and (niv>=3) ) then MPLAB:=1 else MPLAB:=0;
if (port and (niv>=0) ) then FTDI:=1 else FTDI:=0;
if (port and (niv>=0) ) then teamviewer:=1 else teamviewer:=0;
if (port and (niv>=3) ) then IFM:=1 else IFM:=0;
if (port and (niv>=3) ) then VALENCE:=1 else VALENCE:=0;
if (port and (niv>=3) ) then VENSCO:=1 else VENSCO:=0;
if (port and (niv>=0) ) then InitMysql:=1 else InitMysql:=0;
end;
procedure TForm1.ENTERClick(Sender: TObject);
var
MyList:TStringList;
begin
select();
listbox1.Clear;
MyList :=TStringList.Create;
try
if (Dropbox=1) then MyList.Add('Install Dropbox');
if (Msql=1) then MyList.Add('Install Msql');
if (ixxat=1) then MyList.Add('Install ixxat');
if (MPLAB=1) then MyList.Add('Install MPLAB');
if (FTDI=1) then MyList.Add('Install FTDI');
if (teamviewer=1) then MyList.Add('Install teamviewer');
if (IFM=1) then MyList.Add('Install IFM');
if (VALENCE=1) then MyList.Add('Install VALENCE');
if (VENSCO=1) then MyList.Add('Install VENSCO');
if (InitMysql=1) then MyList.Add('Install InitMysql');
begin
ListBox1.Items.AddStrings(MyList);
end;
finally
MyList.Free;
end;
end; |
Partager