#pragma managed/umanaged
-
I'm starting to get back into trying VS.NET with regards to Managed C++. Originally I found the IDE pretty clumsy (since everything I had known and fought to learn in VS6 had moved or morphed :) but its starting to get a little easier to understand. I noticed that you can specify regions of code to be managed and unmanaged using the pragma directive, and was wondering how rigorously other developers used them? Do you explicity add the unmanaged command to the top of your classes, and then if a function does call managed code, this is then declared managed before unmanaging it afterwards? I was considering going all out C#, but there does seem to be quite a slow-down (and I'm still pining for the Doc/View architecture and Windows forms equivalent support for GUI extensions). I'm still debating over weather to use a .NET assembly for data access, and then make use of C++'s interoperability to develop a largely MFC based client, but calling into managed classes for accessing data. I presume its possible to use managed extensions with ATL too -- I'll probably end up doing one or two shell extensions, and possibly a few Office add-ins :) Thanks, Paul -- Paul "It's always the last drink that kills you." [a wise man] MS Messenger: paul@oobaloo.co.uk Sonork: 100.22446
-
I'm starting to get back into trying VS.NET with regards to Managed C++. Originally I found the IDE pretty clumsy (since everything I had known and fought to learn in VS6 had moved or morphed :) but its starting to get a little easier to understand. I noticed that you can specify regions of code to be managed and unmanaged using the pragma directive, and was wondering how rigorously other developers used them? Do you explicity add the unmanaged command to the top of your classes, and then if a function does call managed code, this is then declared managed before unmanaging it afterwards? I was considering going all out C#, but there does seem to be quite a slow-down (and I'm still pining for the Doc/View architecture and Windows forms equivalent support for GUI extensions). I'm still debating over weather to use a .NET assembly for data access, and then make use of C++'s interoperability to develop a largely MFC based client, but calling into managed classes for accessing data. I presume its possible to use managed extensions with ATL too -- I'll probably end up doing one or two shell extensions, and possibly a few Office add-ins :) Thanks, Paul -- Paul "It's always the last drink that kills you." [a wise man] MS Messenger: paul@oobaloo.co.uk Sonork: 100.22446