|
True...but the lower the version, it works on almost any computer.
Hint: The .NET (managed) C++/CLI requires .NET framework installation (and also internet to install it).
So what would you say is better overall...
|
|
|
|
|
It is better having a modern C++ compiler (NOT a C++/CLI one*, C++/CLI is NOT standard C++ , is a Microsoft 'extension'). Modern C++ compilers produce native code like older ones do (very outdated C++ compiler, e.g. turbo C++ , produce code not running on modern computers).
(*) Or use the 'C++/CLI enabled' compiler for compiling standard C++ code. As I said before, Microsoft compiler CAN produce native (not requiring the .NET framework) code.
Veni, vidi, vici.
|
|
|
|
|
How would you do that, could you show me like going into the menus into the "Microsoft Visual C++ compiler"?
|
|
|
|
|
On Visual Studio 2005 (the one I have here) click the menu item New->Project and then choose one of either Win32 or MFC project templates.
Veni, vidi, vici.
|
|
|
|
|
Thanks...appreciate it
|
|
|
|
|
You might have to do some digging around to find those old compilers.
'Lattice C' was the first C compiler I ever used. It was available for DOS and was used by NASA in the 1980s.
The first C++ compilers weren't really compilers. There were pre-compilers. They would convert the C++ code to C code, then you'd compile and link the C code it produced.
|
|
|
|
|
Google for 'turbo c++' There are lots of free downloads of the ancient Borland products, back to the days when the c++ standard was still evolving.
Cheers,
Peter
Software rusts. Simon Stephenson, ca 1994.
|
|
|
|
|
I'm trying to find a 64-bit version of Turbo...none of them seem to work on my computer. (Compatbility problems...)
|
|
|
|
|
Turbo C++ 2.0 is still available on some websites to download.
But I am rather confused by this post. Why would you need the old compiler? and as for the unmanaged part, C++ modern compiler are unmanaged too. the CLI version of C++ is different. (just wondering)
|
|
|
|
|
The lower the version, the chanes of it working on any computer is increased.
|
|
|
|
|
It will/might work on computers of that era, but not on new computers.
You will need to have a DOS (16bit) virtual machine running. (have a look at dosbox)
Watched code never compiles.
|
|
|
|
|
Not true, most old compilers are designed for specific systems just the same. If you want a compiler that works anywhere then go for the GNU versions (gcc/g++) which need to be configured and built on the target system; of course this means you need a previous compiler to build it. You have not said which platform you are targeting so it's not easy to recommend anything else. However I would recommend any of the Express Editions[^] for Windows, gcc for Linux/Unix, and a straightjacket for Mac.
Unrequited desire is character building. OriginalGriff
I'm sitting here giving you a standing ovation - Len Goodman
|
|
|
|
|
Rahul Rajat Singh wrote: Turbo C++ 2.0
Something tells me that wasn't the first C++ compiler...
|
|
|
|
|
Luc Pattyn wrote: that wasn't the first C++ compiler
No it isn't, but it compiles in standard C++. But your right on that part, who knows what was the very first native C++ compiler was...
|
|
|
|
|
Brandon T. H. wrote: I was wondering if any of you'll know any native compilers or compilers the use
the very, very first form/version of C++
The 'first' C++ compiler, CFront, actually produced C code as the output. Which might not be what you expect a compiler to do but which does fit the definition.
You can find source code for CFront. To compile CFront you will need some non-trivial knowledge of C and make files. You will also probably need to make modifications as C wasn't standarized at the time so the library APIs are likely different.
|
|
|
|
|
|
Big thanks
|
|
|
|
|
Would you do all this in a project? for CFront?
|
|
|
|
|
I am loading an extension dll from my mfc client application, when click on the menu first time the dll dialog is being loade and after i exit or close the dialog, and again clicking on the menu to load again it's giving error that "A required resource was unavailable". what could be the problem please help me to resolve this
[code]
void CTestRevApp ::On3DView()
{
typedef VOID (*MYPROC)(CString);
MYPROC ProcAdd;
BOOL fRunTimeLinkSuccess = FALSE;
hinstLib = LoadLibrary(L"C:\\Documents and Settings\\sdh\\My Documents\\REVOLUTIONPROJ_DB\\DllDialog\\package\\DllTest\\Release\\dlltest.dll");
if( hinstLib == NULL)
FreeLibrary(hinstLib);
ProcAdd = (MYPROC)GetProcAddress(hinstLib, "runAppli");
ProcAdd(NULL);
if(ProcAdd == NULL)
{
AfxMessageBox(L"Unable to get pointer to function runAppi()");
FreeLibrary(hinstLib);
hinstLib = NULL;
return;
}
return;
}
[/code]
|
|
|
|
|
Your code looks a little bit mixed up.
Try it this way. It should solve your problem:
CTestRevApp::CTestRevApp()
{
hinstLib = NULL;
}
CTestRevApp::~CTestRevApp()
{
if (hinstLib != NULL)
FreeLibrary(hinstLib);
}
void CTestRevApp::On3DView()
{
typedef VOID (*MYPROC)(CString);
MYPROC ProcAdd;
if (hinstLib == NULL)
{
hinstLib = LoadLibrary(L"C:\\Documents and Settings\\sdh\\My Documents\\REVOLUTIONPROJ_DB\\DllDialog\\package\\DllTest\\Release\\dlltest.dll");
if (hinstLib == NULL)
AfxMessageBox(L"Unable to load library");
}
if (hinstLib != NULL)
{
ProcAdd = (MYPROC)GetProcAddress(hinstLib, "runAppli");
if (ProcAdd == NULL)
AfxMessageBox(L"Unable to get pointer to function runAppi()");
else
ProcAdd(NULL);
}
}
|
|
|
|
|
It's not solving the problem. My Client application is still active when i am calling On3DView 2nd time, it's giving still error "A required resource was unavailable" and not laoding the dlg of the dll.
I have exactly copied your code it's still giving error.
|
|
|
|
|
The error is very probably in your DLL showing a dialog. Common sources are forgetting to release DCs and GDI objects.
|
|
|
|
|
how can i release them manually. Please help me
|
|
|
|
|
Do you have the source code? If not, you must contact the supplier of the DLL. If yes, you must check the code.
If the code uses GetDC() somewhere, ensure that ReleaseDC() is called when the CDC is no longer used.
|
|
|
|
|
I am releasing it in the ::OnDestroy() fucntion of the view
|
|
|
|