Compartilhar via


Como: Adicionar novos itens de projeto

Adding a project item is one way to extend the functionality of an application. Examples of project items include HTML pages, Class files, Web Services, ASP.NET pages, Dataset files, and Style sheets.

The kinds of files that you can add to a project are determined by the project template that was used to create it, and by the version of the .NET Framework targeted by the project. For example, you can add a new .vb file to a project created by using a Visual Basic project template. However, you cannot add a new .vb file to a project created by using a Visual C++ project template. Also, item templates designed for a later version of the .NET Framework do not appear in the templates list for projects that target earlier versions.

ObservaçãoObservação

If your anti-virus software displays a message that offers to block script that the project template or wizard is running, choose not to block script. Se o script estiver bloqueado, em seguida, Visual Studio pode fechar. You can prevent this condition by clearing the anti-virus software setting for blocking script. However, changing this setting disables all script blocking.

To add a new project item

  1. In Solution Explorer, select a target project.

  2. On the Project menu, click Add New Item.

  3. In the Category pane, select a category.

    ObservaçãoObservação

    If only one category exists, this dialog box only contains the Templates pane.

  4. In the Templates pane, select an item template.

  5. Click Open.

Consulte também

Tarefas

Como: Remover, Deletar e excluir itens

Como: Adicionar e remover itens de solução

Referência

Tipos de Arquivo e Extensões de Arquivo no Visual Studio

Conceitos

Usando o Solution Explorer

Gerenciamento de itens em projetos

Introdução às Soluções, Projetos e Itens

Outros recursos

Gerenciando soluções, projetos e arquivos