Page 1 sur 1

[RESOLU] Problème Audit Microsoft Office 2016

Publié : 31 oct. 2022 - 14:03
par dj41ph4
Bonjour,

J'ai un problème en fin d'installation de Microsoft Office

j'ai ce message d'erreur dans le log d'audit du paquet

Voici mon setup

Code : Tout sélectionner

# -*- coding: utf-8 -*-
from setuphelpers import *

r"""
Usable WAPT package functions: install(), uninstall(), session_setup(), audit(), update_package()

"""
# Declaring global variables - Warnings: 1) WAPT context is only available in package functions; 2) Global variables are not persistent between calls


def install():
    # Declaring local variables
 
    # Installing the software
    print("Installation Office 2016 VDB")
run('"setup.exe" /adminfile VDB.MSP', timeout = 1200)
        
Voici mon erreur

Code : Tout sélectionner

Auditing OFFICE2016
Audit aborted due to exception: Command '"setup.exe" /adminfile VDB.MSP' returned non-zero exit status 1.
Output:'"setup.exe"' n'est pas reconnu en tant que commande interne
ou externe, un programme exécutable ou un fichier de commandes.
Pouvez vous m'aider?

d'avance merci

Re: Problème Audit Microsoft Office 2016

Publié : 31 oct. 2022 - 14:25
par t.heroult
Bonjour
a priori, ça veut dire que l'agent ne sait pas où se trouve le fichier setup.exe.
Est-il dans le paquet ?
Dans un sous-dossier du paquet ou à la racine ?

Cordialement,
Tom

Re: Problème Audit Microsoft Office 2016

Publié : 01 nov. 2022 - 10:24
par dj41ph4
L'installation etait correcte mais toujours un problème d'audit,

j'ai changé le code et depuis plus de problème

Code : Tout sélectionner

# -*- coding: utf-8 -*-
from setuphelpers import *

uninstallkey = []
softname = 'Microsoft Office Standard 2016'
pgmsoffice = programfiles



def install():

    if not installed_softwares(softname):
        print('Installation Office 2016')
        cmd = '"setup.exe" /adminfile "silent.msp"'
    else:
        print('Repair and add component to ' + softname)
        cmd = 'msiexec.exe /p silent.msp'

    run(cmd,timeout=1200,accept_returncodes=[1641,3010,0])

    if not installed_softwares(softname):
        error(' %s has been installed but the uninstall key can not be found' % softname)

    #Activation
    pathosppvbs32 = makepath(pgmsoffice,'Microsoft Office','Office16','OSPP.VBS')
    if 'ERROR' in run('cscript "%s" /dstatus'  % pathosppvbs32):
        print("Running activation of " + softname)
        resultact = run('cscript "%s" /act' % pathosppvbs32)

        if 'ERROR' in run('cscript "%s" /dstatus'  % pathosppvbs32):
            error('Activation did not work : ' + resultact)
    else:
        print('Already activated Product')





Re: [RESOLU] Problème Audit Microsoft Office 2016

Publié : 08 nov. 2022 - 16:41
par dcardon
merci dj41ph4 pour ton retour,

Denis