Adding C# code to a legacy C project

Posted on 2004-09-02
Last Modified: 2010-04-15

I have inherited a 10-15 year old C project.  It compiles and runs fine using MS Dev Env 2003 Version 7.1

I would like to start adding some new functions, er, methods, using C#.  Is it possible to intermix C# code with C ?  Is there some magic Paragma statement that will keep the linker happy?
Question by:SparrowVideo
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2

Accepted Solution

jimwasson earned 50 total points
ID: 11970112
No there isn't. Your best option may be to package he old 'C' project as a dll and call it from your new C# program.

Expert Comment

ID: 11984298

I don't think you can do that with C#...only Managed C++...right?
LVL 37

Expert Comment

ID: 11984641
you can call the C# though ... aand in 2005 remember tht you can interchange languages.

Featured Post

PeopleSoft Has Never Been Easier

PeopleSoft Adoption Made Smooth & Simple!

On-The-Job Training Is made Intuitive & Easy With WalkMe's On-Screen Guidance Tool.  Claim Your Free WalkMe Account Now

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Article by: Ivo
C# And Nullable Types Since 2.0 C# has Nullable(T) Generic Structure. The idea behind is to allow value type objects to have null values just like reference types have. This concerns scenarios where not all data sources have values (like a databa…
Introduction Hi all and welcome to my first article on Experts Exchange. A while ago, someone asked me if i could do some tutorials on object oriented programming. I decided to do them on C#. Now you may ask me, why's that? Well, one of the re…
In this brief tutorial Pawel from AdRem Software explains how you can quickly find out which services are running on your network, or what are the IP addresses of servers responsible for each service. Software used is freeware NetCrunch Tools (https…
Add bar graphs to Access queries using Unicode block characters. Graphs appear on every record in the color you want. Give life to numbers. Hopes this gives you ideas on visualizing your data in new ways ~ Create a calculated field in a query: …
Suggested Courses

627 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question