| | |
std: a namespace with this name does not exist
Please support our C++ advertiser: Intel Parallel Studio Home
Thread Solved |
•
•
Join Date: Mar 2007
Posts: 154
Reputation:
Solved Threads: 0
I am having some isues adding std as a namespace. I am using vs2008. don't know if that has something to do with it.
C++ Syntax (Toggle Plain Text)
#pragma once //using namespace System; using namespace std; namespace Email { public ref class Class1 { private: void telnet () { system("dir"); } }; }
C++ Syntax (Toggle Plain Text)
#include "stdafx.h" #include "Email.h" #include <iostream> #include <fstream> #include <String> //#include <cstdio> //#include <stdlib.h> using namespace Email; //using namespace System; //using namespace std; void main() { }
It most certainly does exist, and vs2008 is pretty darn standards-compliant.
Be careful about your capitalization. Also, you must include one of the STL headers to see it.
Try:
However, you have changed the current scope by saying
You might want to try referring to it absolutely (not relatively):
Hope this helps.
Be careful about your capitalization. Also, you must include one of the STL headers to see it.
Try:
C++ Syntax (Toggle Plain Text)
#include <iostream> using namespace std; int main() { cout << "Hello world!" << endl; return EXIT_SUCCESS; }
However, you have changed the current scope by saying
using namespace Email;You might want to try referring to it absolutely (not relatively):
using namespace ::std;Hope this helps.
![]() |
Similar Threads
- iostream or iostream.h??? (C++)
- undeclared identifier (C++)
- How to clear a string (C++)
- Math Functions (C++)
- help!! how do you save a variable to a... (C++)
- need to find occurances in a string (C++)
- I need help with this particular c++ problem (C++)
- How do I pause a Prorgam? (C++)
Other Threads in the C++ Forum
- Previous Thread: ifstream problem ..
- Next Thread: Port Scanner in C++
| Thread Tools | Search this Thread |
api array arrays beginner binary bitmap c++ c/c++ calculator char char* class classes coding compile compiler console conversion convert count data database delete desktop developer directshow dll dynamiccharacterarray email encryption error file forms fstream function functions game generator getline google graph homeworkhelper iamthwee ifstream input int integer java lib linkedlist linux list loop looping loops map math matrix memory multiple news node number numbertoword output parameter pointer problem program programming project proxy python random read recursion recursive reference return rpg sorting string strings struct template templates test text tree unix url vector video visualstudio win32 windows winsock word wordfrequency wxwidgets






