Visual FoxPro: reading .dbf, .scx and .frx files after end of support
What each Visual FoxPro file holds, how to extract data from .dbf and .fpt files safely, and the traps that quietly corrupt a careless migration.
What each Visual FoxPro file holds, how to extract data from .dbf and .fpt files safely, and the traps that quietly corrupt a careless migration.
Who this is for
Anyone responsible for a Visual FoxPro application that still runs the business and that nobody will touch.
Question this answers
Can Visual FoxPro data and logic be recovered, and what is the safest order to do it in?
What you will leave with
Visual FoxPro applications are frequently the best software in the building. They are fast, they were written by somebody who understood the business, and they have run for twenty years without much attention. That is precisely why nobody has dealt with them, and why the decision usually arrives as an emergency rather than a plan.
Microsoft shipped Visual FoxPro 9 in 2004, announced in 2007 that there would be no version 10, and ended extended support on 13 January 2015. There is no successor product and no migration path provided by the vendor.
What did not happen is the applications stopping. A compiled VFP application keeps running on current Windows, which is why so many are still in production a decade after support ended. The pressure comes from somewhere else: the person who wrote it retires, a Windows update breaks a printing or ODBC dependency, or an auditor asks where the data lives and who can access it.
| Extension | What it holds |
|---|---|
.dbf | A table. The actual data, in a documented format |
.cdx | Compound index for the matching .dbf |
.fpt | Memo fields. Notes, descriptions, long text |
.dbc, .dct, .dcx | Database container: relationships, rules, stored procedures |
.prg | Program source. Readable text |
.scx, .sct | Forms, including the code behind them |
.frx, .frt | Report definitions |
.vcx, .vct | Visual class libraries |
.pjx, .pjt | Project file, lists everything that belongs together |
.exe | The compiled application |
The .fpt file is the single most common cause of silent data loss. Memo fields do not live inside the .dbf, they live in a separate .fpt with the same base name. Copy or extract the .dbf on its own and every note, description and comment vanishes without any error being raised. Always move the pair together.
A useful detail: .scx, .frx, .vcx and
.pjx are themselves .dbf files with different
extensions. That means the forms, reports and class libraries can be opened and
read as tables, which is how their contents are recovered when the development
environment is not available.
The .dbf format is documented and old enough to be very widely
supported. You do not need Visual FoxPro installed to read it, which matters
because installing VFP on a current machine is its own small ordeal.
The practical sequence:
The business rules in a VFP application are not in one place, which is the main reason rebuilds get underestimated. Expect to find logic in all of these:
Because all four of those file types are readable as tables, the logic can be recovered systematically even without the development environment. It is methodical work rather than clever work.
Full rebuilds fail more often than staged ones, and Visual FoxPro happens to support a genuinely low-risk sequence:
Each step delivers something on its own. If the project stops after step one, you have still removed the largest risks, which is the mark of a sensible sequence rather than a hopeful one.
The honest summary: Visual FoxPro skills are getting rarer every year, and that is a real constraint on finding help. The data and the logic are not the constraint. Both are recoverable with documented formats and patience.
Microsoft no longer supports Visual FoxPro: extended support ended on 13 January 2015, and Visual FoxPro 9 was the last version. Microsoft announced in 2007 that there would be no version 10, and there is no successor product or vendor migration path. Compiled Visual FoxPro applications still run on current Windows, which is why so many are still in production a decade after support ended.
Yes, Visual FoxPro .dbf files can be read without Visual FoxPro installed. The .dbf format is documented and old enough to be very widely supported, so extraction does not depend on keeping the old environment alive. The form, report, class library and project files (.scx, .frx, .vcx and .pjx) are themselves .dbf files with different extensions, so they can also be opened and read as tables.
Visual FoxPro notes go missing because memo fields are stored in a separate .fpt file with the same base name as the .dbf table. Copy or extract the .dbf on its own and every note, description and comment vanishes without any error. Always move the pair together, and after extraction count the non-empty memo values in the source and the destination and compare them.
Six traps corrupt careless Visual FoxPro migrations: memo fields, deleted records, empty dates, trailing spaces, code pages and currency precision. Deleted records are only marked and stay in the file until the table is packed. Empty dates mapped carelessly become 1899 or 1900. Space-padded fields make joins fail, older code page data loses accented characters, and mapping the Currency type to a float causes rounding differences in totals.
The safest Visual FoxPro migration is usually staged. First move the data to SQL Server while the FoxPro screens keep running through remote views or Open Database Connectivity (ODBC). Then rebuild reporting, replace the screens one module at a time with both systems live, and retire the FoxPro application only when the last screen has moved. Each step delivers something on its own, so stopping after step one still removes the largest risks.
Ask the author
Ask it here and it comes straight to Kasun, who wrote this. No sales call, no obligation, and a real answer even if the answer is that you do not need us.
Kasun Wijayamanna
Founder, replies within one business day
Tell us what you are comparing, replacing, or trying to improve. We will come back with a practical recommendation and realistic scope.
Built here. Your data stays here.
Thanks for reaching out. We will get back to you within one business day.
See what else we do