Link to home
Create AccountLog in
Avatar of mathu76
mathu76

asked on

C# versis VC++.Net

Hi Experts

I am an application programmer primarily working in VC++ (MFC) & Sockets.
I also have some VB knowledge too.
This is my first question here in VC++.Net zone.

If this question is invalid please spare me.

Q1. Does C# & VC++.Net means the same? If not what are the differences.
Q2. Does C# support use of Pointers?
Q3. Can the dll's that i use with my VC++ SDI MFC Appllications be used with C# application without modifications. The dll's does the loww level job such as reading Hard disk sectors.

Waiting for comments
Regards
   
 
Avatar of AlexFM
AlexFM

Q1. Using managed C++ you can do all things available in C# and much more. Managed C++ allows writing mixed applications which use both managed and unmanaged code (and they can use any legacy C++ code directly). However, managed C++ will be changed significantly in new release of Visual Studio 2005. If you want to start developing in managed C++, possibly it is better to wait for 2005 release.

Q2. Yes - see Unsafe Programming.

Q3. C# can use two types of unmanaged libraries:
- COM libraries - directly.
- Dll which exposes C-style interface (API) - like API calls in VB6. See PInvoke.
C# and managed C++ have big similarities, as AlexFM explained, but definitively them are not the same language. Them have different purposes. C# is a high level language, intended IMHO to compete directly with Java, C++ is a mid level language, it is more "sticked" to hardware and has a better performance for highly intensive calculation tasks.
Here is an article explaining some differences:
http://www.itgatewaysolutions.com/articles/CPlusAndCSharp.htm
ASKER CERTIFIED SOLUTION
Avatar of Jaime Olivares
Jaime Olivares
Flag of Peru image

Link to home
membership
Create a free account to see this answer
Signing up is free and takes 30 seconds. No credit card required.
See answer
Avatar of mathu76

ASKER

sorry was out of station for last few days!

thanks for ur suggestions

Regards