Solved

Need a foxpro created dll be read by a program that requires BorlandC compiled dlls

Posted on 2013-01-10
3
320 Views
Last Modified: 2013-08-08
I have heard that there is a way to do this, any help would be appreciated.

I need to be able to use and maintain a dll that is coded in visual FoxPro to be understood by another program that can only understand a VisualC or BorlandC compiled dll. I have heard that a wrapper can be created to accomplish this.

Steps to do this would be a big help if anyone knows how.

Thanks again!

BC
0
Comment
Question by:busycoder
  • 2
3 Comments
 
LVL 41

Assisted Solution

by:pcelba
pcelba earned 250 total points
Comment Utility
You may create COM DLLs in FoxPro and call them from .NET or other programs understanding COM interface. Some examples are here: http://www.vfpconversion.com/article.aspx?quickid=030034

Another option is a FLL library which is FoxPro API DLL written in C which you may call from FoxPro only... Not suitable for this case.

So you'll need to find a C programmer which is able to write a standard DLL with a defined set of entry points and which you may call from C (or even from FoxPro and other languages after appropriate declarations) and which will call given COM DLLs created in FoxPro... A lot of work.

You may start here: http://en.wikipedia.org/wiki/Dynamic-link_library
http://msdn.microsoft.com/en-us/library/windows/desktop/ms682592(v=vs.85).aspx
http://www.icynorth.com/development/createdlltutorial.html

And how to call COM DLL from C is described e.g. here: http://www.experts-exchange.com/Programming/Languages/CPP/Q_10255178.html

It is probably better to ask this question in C forums.
0
 
LVL 29

Accepted Solution

by:
Olaf Doschke earned 250 total points
Comment Utility
The question rather is, why should this be a foxpro DLL? Do you need to access DBFs? I anything else Foxpro specific in the focus of this DLL?

If not Foxpro has nothing to do with it.

What is the programming language, that would use this DLL?

Ways to access VFP data from non VFP applilcations could also be:
1. VFP ODBC driver (needs ODBC capability, for old DBFs up to VFP6 features)
2. VFP OLEDB Provider (needs OLE/COM capabilities, can access any VFP DBF)
3. Put data access to a service, you either create by using VFP, creating a COM DLL and publishing it to an IIS via the Soap Toolkit or programm something via ActiveVFP putting data into XML or JSON or some other format you can make use of in any application/language needing your data.

I would recommend them in that order. No need to go for a VFP created DLL in tzhe first, if data is your goal, this rather is a last resort. It can indeed help to get more than just the data and to reuse some of the VFP code and logic you have to process data. If that is needed a web service may be a solution for internet or intranet, but it's an overhead for a single user desktop application.

Bye, Olaf.
0
 
LVL 41

Expert Comment

by:pcelba
Comment Utility
Yes, VFP ODBC and OLE DB is mentioned in the first link above. It should also be possible to call VFP stored procedure from any language.

BUT possible solutions are reduced to "program that can only understand a VisualC or BorlandC compiled dll"... Of course, it does not mean the third way is not achievable.
0

Featured Post

Why You Should Analyze Threat Actor TTPs

After years of analyzing threat actor behavior, it’s become clear that at any given time there are specific tactics, techniques, and procedures (TTPs) that are particularly prevalent. By analyzing and understanding these TTPs, you can dramatically enhance your security program.

Join & Write a Comment

Suggested Solutions

Microsoft Visual FoxPro (short VFP) is a programming language with it’s own IDE and database, ranking somewhat between Access and VB.NET + SQL Server (Express). Product Description: http://msdn.microsoft.com/en-us/vfoxpro/default.aspx (http://msd…
This article explains how to prepare an HTML email signature template file containing dynamic placeholders for users' Azure AD data. Furthermore, it explains how to use this file to remotely set up a department-wide email signature policy in Office …
Sending a Secure fax is easy with eFax Corporate (http://www.enterprise.efax.com). First, Just open a new email message.  In the To field, type your recipient's fax number @efaxsend.com. You can even send a secure international fax — just include t…
Here's a very brief overview of the methods PRTG Network Monitor (https://www.paessler.com/prtg) offers for monitoring bandwidth, to help you decide which methods you´d like to investigate in more detail.  The methods are covered in more detail in o…

728 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

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now