![]() |
|
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Newbie
Join Date: Jul 2005
Posts: 1
Rep Power: 0
![]() |
The Grand Programming Language Reunion (Delphi->C)
This is probably the worst thing I've ever tried to do, but I'm going to attempt to try to do it anyway.
I have a whole bunch of C functions that I wrote for a project at one point. Well, since I'm now attempting to do this graphically, is there a way to call these functions from Delphi, without needing to rewrite them. Now I'm assuming that there is, but there are a few problems with the functions: The first is, they all return a value of some sort (I'm pretty sure all integers). But more importantly, they all accept 2 values (eventually all 1-2 integers, and a string [or char[] or char * as needed]). Is there actually a way to call these functions (possibly by compiling the C code into another form...maybe?)? Or should I go ahead and rewrite all of them (just around 90-100). |
|
|
|
|
|
#2 |
|
I eat cake for breakfast.
![]() ![]() ![]() ![]() Join Date: Jul 2004
Location: In my box.
Posts: 4,434
Rep Power: 9
![]() |
I think the best way is to compile the C functions into a DLL (Dynamic Link Library) - then you should be able to call the functions from the DLL in your Delphi project. MSDN will help you with making the DLL, but unfortunately I don't know nearly enough Delphi to help you with the second part.
|
|
|
|
![]() |
| Bookmarks |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|