Find Jobs
Hire Freelancers

Translate short Delphi DLL (129 lines) to Visual Studio C++(repost)

$100-500 USD

Cancelled
Posted over 13 years ago

$100-500 USD

Paid on delivery
Translate a short (129 lines) Delphi DLL to a Visual Studio C++ Project. You find the Delphi DLL Source in the description. ## Deliverables I tried to translate it on my own. Here is my C++ trial that does not work. Maybe you can use it as a starting point: #ifndef _DLL_H_ #define _DLL_H_ #if BUILDING_DLL # define DLLIMPORT __declspec (dllexport) #else /* Not BUILDING_DLL */ # define DLLIMPORT __declspec (dllimport) #endif /* Not BUILDING_DLL */ #include <[login to view URL]> class DLLIMPORT DllClass { public: DllClass(); virtual ~DllClass(void); private: }; class TMyClass; struct TRegisterProcRec; { typedef int __fastcall (*TRegisterNamespace )( int , const String ); typedef int __fastcall (*TRegisterConstant )( int , const String , const Variant ); typedef int __fastcall (*TRegisterVariable )( int , const String , int , void* ); typedef int __fastcall (*TRegisterHeader )( int , const String , void* , int = 0, int = 0 ); typedef int __fastcall (*TRegisterProperty )( int , const String ); typedef int __fastcall (*TRegisterClassType )( int , TMetaClass* , bool = false ); typedef int __fastcall (*TRegisterClassReferenceType )( int , const String , const String ); typedef int __fastcall (*TRegisterClassTypeField )( int , const String ); typedef int __fastcall (*TRegisterRecordType )( int , const String , bool = false ); typedef int __fastcall (*TRegisterRecordTypeField )( int , const String ); typedef int __fastcall (*TRegisterVariantRecordTypeField )( int , const String , __int64 ); typedef int __fastcall (*TRegisterEnumType )( int , const String , int = 7 ); typedef int __fastcall (*TRegisterEnumValue )( int , const String , const int ); typedef int __fastcall (*TRegisterSubrangeType )( int , const String , int , int , int ); typedef int __fastcall (*TRegisterArrayType )( int , const String , int , int , bool = false ); typedef int __fastcall (*TRegisterDynamicArrayType )( int , const String , int ); typedef int __fastcall (*TRegisterPointerType )( int , const String , int ); typedef int __fastcall (*TRegisterSetType )( int , const String , int ); typedef int __fastcall (*TRegisterProceduralType )( int , const String , int ); typedef int __fastcall (*TRegisterEventType )( int , const String , int ); typedef int __fastcall (*TRegisterShortStringType )( int , const String , int ); typedef int __fastcall (*TRegisterInterfaceType )( int , const String , const TGUID , const String , const TGUID ); // TRegisterRTTIType = function(LevelId: Integer; pti: PTypeInfo): Integer; typedef int __fastcall (*TRegisterTypeAlias )( int , const String , int ); struct TRegisterProcRec { TRegisterNamespace RegisterNamespace; TRegisterConstant RegisterConstant; TRegisterVariable RegisterVariable; TRegisterHeader RegisterHeader; TRegisterProperty RegisterProperty; TRegisterClassType RegisterClassType; TRegisterClassTypeField RegisterClassTypeField; TRegisterClassReferenceType RegisterClassReferenceType; TRegisterRecordType RegisterRecordType; TRegisterRecordTypeField RegisterRecordTypeField; TRegisterVariantRecordTypeField RegisterVariantRecordTypeField; TRegisterEnumType RegisterEnumType; TRegisterEnumValue RegisterEnumValue; TRegisterSubrangeType RegisterSubrangeType; TRegisterArrayType RegisterArrayType; TRegisterDynamicArrayType RegisterDynamicArrayType; TRegisterPointerType RegisterPointerType; TRegisterSetType RegisterSetType; TRegisterProceduralType RegisterProceduralType; TRegisterEventType RegisterEventType; TRegisterShortStringType RegisterShortStringType; TRegisterInterfaceType RegisterInterfaceType; TRegisterTypeAlias RegisterTypeAlias; }; typedef void __fastcall (*TRegisterDllProc )( const TRegisterProcRec& ); class TMyClass: public System::TObject { public: void __fastcall P( ); public: inline __fastcall TMyClass () {} }; const int MyConst = 123; int __fastcall MyFunc( int x, int y, int& MyConst ) { int result = 0; result = x + y; return result; } void __fastcall TMyClass::TMyClass::P( ) { writeln( 'P' ); } void __fastcall RegisterDllProcs( const TRegisterProcRec& PaxRegisterProcs, int& MyConst ) { int G = 0, H = 0; { H = [login to view URL]( 0, "u2" ); [login to view URL]( H, "MyConst", 123 ); G = [login to view URL]( H, __classid( TMyClass ) ); [login to view URL]( G, "procedure P;", &TMyClass::P()); [login to view URL]( G, "constructor Create;", __classid( new TMyClass ) ); [login to view URL]( H, "function MyFunc(X, Y: Integer): Integer;", &MyFunc( , MyConst) ); } } exports RegisterDllProcs; } #endif /* _DLL_H_ */
Project ID: 2994140

About the project

1 proposal
Remote project
Active 13 yrs ago

Looking to make some money?

Benefits of bidding on Freelancer

Set your budget and timeframe
Get paid for your work
Outline your proposal
It's free to sign up and bid on jobs
1 freelancer is bidding on average $85 USD for this job
User Avatar
See private message.
$85 USD in 14 days
5.0 (65 reviews)
6.6
6.6

About the client

Flag of GERMANY
Germany
5.0
2
Member since Dec 20, 2010

Client Verification

Thanks! We’ve emailed you a link to claim your free credit.
Something went wrong while sending your email. Please try again.
Registered Users Total Jobs Posted
Freelancer ® is a registered Trademark of Freelancer Technology Pty Limited (ACN 142 189 759)
Copyright © 2024 Freelancer Technology Pty Limited (ACN 142 189 759)
Loading preview
Permission granted for Geolocation.
Your login session has expired and you have been logged out. Please log in again.