473,320 Members | 1,856 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

another c++ app rewrite question

I have the SDK and API Libraries of XXX.

The programming guide states:

"
An XXX program using the XXX Libraries should be compiled with
Microsoft Visual C++ Version 6.0. The XXX program will need to include
the file <TARGETDIR>\Include\XXXLib.h. The linker will need to have
<TARGETDIR>\Lib added to its Library path or explicitly link with
XXXLib16.lib, XXXComm.lib and XXXLogClient.lib in the directory
<TARGETDIR>\Lib.
"

Yet, my direction is to rewrite an existing XXX program in c#.

I've been reading up on interop services, RCW, and running unmanaged
C++ code in C#. Since I'm rewriting something, I dont write a wrapper
for it, right?

Am im supposed to turn the XXX libraries into COM objects and then use
them in C#? And I do this by using the C++ 6.0 IDE?

Is there a better way?

TIA

Aug 23 '06 #1
1 1255
If possible get the libraries for VC8; at least you can then work under one
development environment then.

Several possible routes available:

1. If you can get a COM/ActiveX component from the library vendor then use
Interop.

2. If it's your own library then port it to a C# assembly. If the library
functionality can be easily re-written then re-write the code in C#.

3. Either wrap it as a DLL or COM component and use PInvoke or Interop
respectively. This can get messy depending on what parameters the wrapped
methods need to take and you may need to write some infrastructure adaptors
to allow passing .NET types to the methods easily.

- Andy

<jo*********@lycos.comwrote in message
news:11*********************@i3g2000cwc.googlegrou ps.com...
>I have the SDK and API Libraries of XXX.

The programming guide states:

"
An XXX program using the XXX Libraries should be compiled with
Microsoft Visual C++ Version 6.0. The XXX program will need to include
the file <TARGETDIR>\Include\XXXLib.h. The linker will need to have
<TARGETDIR>\Lib added to its Library path or explicitly link with
XXXLib16.lib, XXXComm.lib and XXXLogClient.lib in the directory
<TARGETDIR>\Lib.
"

Yet, my direction is to rewrite an existing XXX program in c#.

I've been reading up on interop services, RCW, and running unmanaged
C++ code in C#. Since I'm rewriting something, I dont write a wrapper
for it, right?

Am im supposed to turn the XXX libraries into COM objects and then use
them in C#? And I do this by using the C++ 6.0 IDE?

Is there a better way?

TIA

Aug 24 '06 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

51
by: nospam | last post by:
THIS IS the DOTNETJUNKIES MESSAGE ------------------------- We're Sorry As many of you know we have recently launched SqlJunkies.com. We have overhauled our runtime and will be using it on...
188
by: christopher diggins | last post by:
I have posted a C# critique at http://www.heron-language.com/c-sharp-critique.html. To summarize I bring up the following issues : - unsafe code - attributes - garbage collection -...
5
by: T | last post by:
Hi group, I'm trying to create a temporary replacement scheme for a particular url that gets generated all over an existing app. It would be very difficult to find every spot where the url gets...
14
by: Stan Canepa | last post by:
This post is mostly for discussion. Why rewrite in .NET? Just a general discussion not related to any specific details. I was just looking to see what reasons developers are looking to, to help...
4
by: mainargv | last post by:
hi How do you rewrite codes with " ... va_list va_start va_etc", so that simple c compiler don't have to deal with them. I have written a simple c->verilog compiler but it can't deal with...
8
by: Jorge | last post by:
On Jun 5, 3:36 pm, sheldonlg <sheldonlgwrote: What's wrong with that ? I'd say that that's perfect. Why don't you like it this way ? But just for the sake of changing something : function...
22
by: sheldonlg | last post by:
I am looking for a clean solution to a problem that I solved in, what I call, a "dirty" way. Here is what I want to do. I have a dropdown list. Clicking on an item in the dropdown list invokes...
3
by: aag | last post by:
Hey there! I've got an URL rewrite issue that I'm wondering if the masters out there can help with :) I have a site that resides at (for example) foo.com - it's a full site with tons of pages...
2
by: LC's No-Spam Newsreading account | last post by:
On Tue, 7 Oct 2008, Grant wrote: I carefully RTFM, but can't find an example like my case. What is the " fake directory cgi option" ? (in general I avoid using /cgi-bin or personal...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
0
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.