AddFilesToProject

Aggiornamento: novembre 2007

Consente di aggiungere al progetto tutti i file elencati in Templates.inf.

function AddFilesToProject( 
      oProj, 
      strProjectName, 
      InfFile  
);

Parametri

  • oProj
    Progetto selezionato.

  • strProjectName
    Il nome del progetto.

  • InfFile
    Oggetto file Templates.inf. Il file contiene un elenco dei nomi di file creati al completamento della procedura guidata.

Note

Chiamare questa funzione per aggiungere al progetto tutti i file elencati in Templates.inf. Utilizzando questa funzione, è possibile aggiungere file modello, file di risorse o file della Guida.

Esempio

// Assign the project path and project name.
var strProjectPath = wizard.FindSymbol("PROJECT_PATH");
var strProjectName = wizard.FindSymbol("PROJECT_NAME");

// Create the Visual C++ project and call it "MyProj"
selProj = CreateProject(strProjectName, strProjectPath);
selProj.Object.Keyword = "MyProj";

// Add common and specific configurations to the project.
AddCommonConfig(selProj, strProjectName);
AddSpecificConfig(selProj, strProjectName);

// Set the project filters
SetFilters(selProj);

// Create the project's Templates.inf file 
var InfFile = CreateInfFile();

// Add the files in Templates.inf to the project.
AddFilesToProject(selProj, strProjectName, InfFile);

Vedere anche

Attività

Creazione di una procedura guidata personalizzata

Concetti

Personalizzazione delle procedure guidate C++ con funzioni comuni JScript

Progettazione di una procedura guidata

Riferimenti

CreateInfFile

SetCommonPchSettings

Altre risorse

Funzioni JScript per procedure guidate C++