salut !
l'install de cette application marche avec xp et moi j'aimerai bien avec windows 7, à vous les programmeurs !! svp !
REP: DOTNETFX
REP: MICROSOFT8VS20108VCREDIST8X86
REP: PLANCOMPTABLEASSISTANT
REP : WINDOWSINSTALLR485
FILE : COMPONENTS
FILE : DATA
FILE : INSTALL
FILE : SETUP
edition du fichier install extension vbs ,voilà :
Option Explicit
Dim objWMIService, colOperatingSystems, objOperatingSystem
Set objWMIService = GetObject("winmgmts:{impersonationLevel=impersonate}!\\.\root\cimv2")
Set colOperatingSystems = objWMIService.ExecQuery ("Select * from Win32_OperatingSystem")
For Each objOperatingSystem in colOperatingSystems
Dim sp, name, pos
sp = objOperatingSystem.CSDVersion
name = objOperatingSystem.Name
pos = InStr(name, "|")
If pos <> 0 Then
name = Mid(name, 1, pos - 1)
End If
If name <> "Microsoft Windows XP Professional" Or (sp <> "Service Pack 2" And sp <> "Service Pack 3") Then
MsgBox "Unsupported version: " & name & " " & sp, vbOKOnly + vbCritical, "Error"
WScript.Quit
End If
Exit For
Next
If MsgBox("Demarrer installation?", vbYesNo+vbQuestion , "Install") = vbYes Then
Dim objShell, cmd, ret
Set objShell = CreateObject("WScript.Shell")
' 1. Installation de IIS & Framework .net 2.0
' cmd = "sysocmgr.exe /i:C:\WINDOWS\inf\sysoc.inf ""/u:" & objShell.currentdirectory & "\components.inf"" /r"
' ret = objShell.Run(cmd, 1, true)
' On Error Resume Next
' ret = objShell.RegRead("HKLM\SOFTWARE\Microsoft\NET Framework Setup\NDP\v2.0.50727\Install")
' If Err.Number <> 0 Or ret <> 1 Then
' Err.Clear
' MsgBox ".Net Framework 2.0 is missing", vbOKOnly + vbCritical, "Error"
' WScript.Quit
' End If
' On Error Goto 0
' 1. Installation du Framework .net 2.0
If MsgBox("Voulez vous Installer Framework .net 2.0 ?", vbYesNo+vbQuestion , "Install") = vbYes Then
cmd = "dotnetfx\dotnetfx.exe"
ret = objShell.Run(cmd, 1, true)
End If
' 2. Installation du Visual C++ 2010 Redistributable néxessaire à l'installable postgresql-9.3
If MsgBox("Voulez vous Installer Microsoft Redistribuable VS2010?", vbYesNo+vbQuestion , "Install") = vbYes Then
cmd = "Microsoft_VS2010_vcredist_x86\vcredist_x86.exe /q:a"
ret = objShell.Run(cmd, 1, true)
End If
' 3. Installation de Postaldesktop
cmd = "setup.exe"
ret = objShell.Run(cmd, 1, true)
'If ret <> 0 Then
' MsgBox "Error " & ret & " during install", vbOKOnly + vbCritical, "Error"
'Else
' MsgBox "Install finished", vbOKOnly +vbInformation , "Install"
'End If
End If