powered by simpleCommunicator - 2.0.61     © 2026 Programmizd 02
Целевая тема:
Создать новую тему:
Автор:
Закрыть
Цитировать
Форумы / C++ [игнор отключен] [закрыт для гостей] / Объсните тупому. //HELP
8 сообщений из 8, страница 1 из 1
Объсните тупому. //HELP
    #32317583
Gerbilin
Скрыть профиль Поместить в игнор-лист Сообщения автора в теме
Гость
Только начинаю изучение С++, и сталкнулся с проблемой
Почему, когда запускаю Debug, выдаётся сообщение об ошибке?
c:\documents and settings\владимир\мои документы\visual studio projects\new\new.cpp(5): fatal error C1083: Cannot open include file: 'iostream.h': No such file or directory //Line 5.
Код:
//Name
//Отображение на экране слова Name

#include "stdafx.h"
#include <iostream.h>

int _tmain(int argc, _TCHAR* argv[])
{
//Вывод на экран
cout << "Name\n";
return 0;
}

Если это важно у меня Visual Studio.net 2003 Enterprise Architect

Заранее спасибо.

заменяю #include <iostream.h> на #include <iostream> и теперь выдаётся ошибак c:\documents and settings\владимир\мои документы\visual studio projects\new\new.cpp(10): error C2065: 'cout' : undeclared identifier // Line 10

В чём дело?
...
Рейтинг: 0 / 0
Объсните тупому. //HELP
    #32317592
Evgenye
Скрыть профиль Поместить в игнор-лист Сообщения автора в теме
Гость
Следует проверить настройку директорий к include файлам.
...
Рейтинг: 0 / 0
Объсните тупому. //HELP
    #32317599
Gerbilin
Скрыть профиль Поместить в игнор-лист Сообщения автора в теме
Гость
Тупой вопрос: А как это сделать и что именно надо исправить? Если не сложно объясните.
Буду очень благодарен.
...
Рейтинг: 0 / 0
Объсните тупому. //HELP
    #32317634
vasyap
Скрыть профиль Поместить в игнор-лист Сообщения автора в теме
Гость
The Additional Include Directories option (/Idirectory) adds one or more directories to the list of directories searched for include files. Directories are searched only until the specified include file is found. You can use this option with the Ignore Standard Include Paths (/X) option.

In the Project Settings dialog box, use a comma to separate directories to be searched when entering more than one directory. (To find this option in the development environment, click Settings on the Project menu. Then click the C/C++ tab, and click Preprocessor in the Category box.)

On the command line, a space between /I and directory is optional. To search more than one directory, type one /I option for each directory.

The compiler searches for directories in the following order:

Directories containing the source file.


Directories specified with the /I option, in the order that CL encounters them.


Directories specified in the INCLUDE environment variable.
Example
The following command looks for the include files requested by MAIN.C in the following order: first in the directory containing MAIN.C, then in the \INCLUDE directory, then in the \MY\INCLUDE directory, and finally in the directories assigned to the INCLUDE environment variable.

CL /I \INCLUDE /I\MY\INCLUDE MAIN.C
...
Рейтинг: 0 / 0
Объсните тупому. //HELP
    #32317655
Gerbilin
Скрыть профиль Поместить в игнор-лист Сообщения автора в теме
Гость
А я немецкий всю жизнь учил, можно по русски, плиз.
...
Рейтинг: 0 / 0
Объсните тупому. //HELP
    #32317677
ixane
Скрыть профиль Поместить в игнор-лист Сообщения автора в теме
Гость
Там в самой IDE какие-то настройки (в меню поискать), а там вкладка Directories - там надо прописать путь где у тебя include-файлы(Папка INCLUDE), а можно просто скопировать необходимый инклюд в папку проекта и заменить в коде < > на " "
...
Рейтинг: 0 / 0
Объсните тупому. //HELP
    #32317808
std::cout
либо
using namespace std;
...
Рейтинг: 0 / 0
Объсните тупому. //HELP
    #32317903
Gerbilin
Скрыть профиль Поместить в игнор-лист Сообщения автора в теме
Гость
Большое, человеческое спасибо. Поменял cout << "Name\n"; на std::cout << "Name\n"; и #include <iostream.h> на #include <iostream> и всё заработало. Спасибо.
...
Рейтинг: 0 / 0
8 сообщений из 8, страница 1 из 1
Форумы / C++ [игнор отключен] [закрыт для гостей] / Объсните тупому. //HELP
Найденые пользователи ...
Разблокировать пользователей ...
Читали форум (0):
Пользователи онлайн (0):
x
x
Закрыть


Просмотр
0 / 0
Close
Debug Console [Select Text]