Click here to Skip to main content
15,881,812 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi All,

1. I am new to Managed C++, In my program, based on C++, In case I need to make a transition to Managed C++ and use the equivalent constructs.

Eg.,


System::String ^ ptr = gcnew ("C:\Dir1\abc.txt");
// SomeClass ObjSomeClass should consume the <<ptr>> in MC++
and input the above ptr in the Class someClass
Could you let me know the approach by using the Managed C++,
Basically the above path should be available to the someclass in managed C++,

2. Are there any prerequisites other than including the following in Unmanaged Code to obtain autocompletion/intellisense to able to invoke Managed Code(C++/CLI)


#include "Stdafx.h"
.....
using <mscorlib.dll>
using System;
using System::EnterpriseServices::Internal;
....


Adding References using the project properties for System::EnterpriseServices::Internal and also setting the .NET Framework to 3.5 and above
also, Compiler Switch Settings to using /CLR.
despite of the above inclusions, still I am unable to invoke Managed Code(C++/CLI) Please let me know the process to resolve the same.



any help in resolving the above would be much appreciable.

Regards,
VishalK_90
Posted
Comments
Sergey Alexandrovich Kryukov 14-May-13 14:27pm    
There is no such thing as "Managed C++". In the past, it was "Managed C++ extensions", presently superseded with C++/CLI.
—SA
Sergey Alexandrovich Kryukov 14-May-13 14:30pm    
What do you mean by "transition"?
—SA

1 solution

Intellisense for C++/CLI does not work on VS2010. I believe it is working in VS2012 though, so you might want to upgrade to that if you can.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900