> ## Documentation Index
> Fetch the complete documentation index at: https://devdocs.xbox.com/llms.txt
> Use this file to discover all available pages before exploring further.

# XtfRegisterPackage

> XtfRegisterPackage

# XtfRegisterPackage

Inscrit un package déployé sur le lecteur de travail du titre (title scratch drive).

<a id="syntaxSection" />

## Syntaxe

```cpp theme={null}
HRESULT XtfRegisterPackage(
         LPCWSTR address,
         LPCWSTR titleScratchRelativePath,
         XtfPackageInfo* packageInfo
)  
```

<a id="parametersSection" />

### Paramètres

*address*\
Type : LPCWSTR

\[in] Adresse de la console.

*titleScratchRelativePath*\
Type : LPCWSTR

\[in] Chemin relatif, sur le lecteur de travail du titre, du package à inscrire.

*packageInfo*\
Type : XtfPackageInfo\*

\[out] Objet d'informations de package relatif au package qui a été inscrit.

<a id="retvalSection" />

### Valeur de retour

Type : HRESULT

Retourne `S_OK` en cas de réussite ; sinon, retourne un code d'erreur HRESULT.

<a id="remarksSection" />

## Remarques

Cette fonction inscrit un package déployé sur le lecteur de travail du titre et fournit les informations du package sous la forme d'une référence d'objet `XtfPackageInfo`. Utilisez les fonctions [XtfGetPackageFullName](/fr/reference/tools/xtf/xtfapi/functions/xtfgetpackagefullname-xtfapi-xbox-windows-m), [XtfGetCountofAppUserModelIds](/fr/reference/tools/xtf/xtfapi/functions/xtfgetcountofappusermodelids-xtfapi-xbox-windows-m) et [XtfGetAumid](/fr/reference/tools/xtf/xtfapi/functions/xtfgetaumid-xtfapi-xbox-windows-m) pour obtenir le nom complet du package et les ID de modèle utilisateur d'application (AUMID) du package inscrit à partir de l'objet `XtfPackageInfo`. Utilisez [XtfClosePackageInfo](/fr/reference/tools/xtf/xtfapi/functions/xtfclosepackageinfo-xtfapi-xbox-windows-m) pour libérer l'objet `XtfPackageInfo` lorsque vous n'en avez plus besoin.

Vous pouvez également utiliser [XtfUnregisterPackage](/fr/reference/tools/xtf/xtfapi/functions/xtfunregisterpackage-xtfapi-xbox-windows-m) pour désinscrire un package. Pour plus d'informations sur la gestion des applications, consultez [Gestion des applications (xbapp.exe) (rubrique NDA)](/fr/tools/tools-console/commandlinetools/xbapp).

<a id="requirementsSection" />

## Configuration requise

**En-tête :** xtfapi.h

**Bibliothèque :** XtfApi.lib

**Plateformes prises en charge :** Windows (pour les outils de console XBOX)

<a id="seealsoSection" />

## Voir aussi

[Erreurs de transport XTF (rubrique NDA)](/fr/tools/tools-console/commandlinetools/xtf-transport-errors)\
[API Xtf supplémentaires](/fr/reference/tools/xtf/xtfapi/atoc-xtfapi)


## Related topics

- [XtfRegisterPackage](/reference/tools/xtf/xtfapi/functions/xtfregisterpackage-xtfapi-xbox-windows-m.md)
- [XtfUnregisterPackage](/reference/tools/xtf/xtfapi/functions/xtfunregisterpackage-xtfapi-xbox-windows-m.md)
