Click here to Skip to main content
15,883,802 members
Articles / Programming Languages / C#

Load a DBF into a DataTable

Rate me:
Please Sign up or sign in to vote.
4.80/5 (72 votes)
11 Mar 2008CPOL6 min read 400.2K   8.3K   87  
Load a DBF into a DataTable without using the Jet or other OLE Db drivers
In this post, you will find a simple class to read an entire DBF into a DataTable. From there, you can use .NET to manipulate the data. You will not find any method to query the data; this loads the entire file and that's it. You probably don't want to use this if you have a DBF with tens of thousands of records or more.
Microsoft Visual Studio Solution File, Format Version 8.00
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "LoadDBF", "LoadDBF.csproj", "{2FB1AEFA-3B28-42D0-9520-3F100E297601}"
	ProjectSection(ProjectDependencies) = postProject
	EndProjectSection
EndProject
Global
	GlobalSection(SolutionConfiguration) = preSolution
		Debug = Debug
		Release = Release
	EndGlobalSection
	GlobalSection(ProjectDependencies) = postSolution
	EndGlobalSection
	GlobalSection(ProjectConfiguration) = postSolution
		{2FB1AEFA-3B28-42D0-9520-3F100E297601}.Debug.ActiveCfg = Debug|.NET
		{2FB1AEFA-3B28-42D0-9520-3F100E297601}.Debug.Build.0 = Debug|.NET
		{2FB1AEFA-3B28-42D0-9520-3F100E297601}.Release.ActiveCfg = Release|.NET
		{2FB1AEFA-3B28-42D0-9520-3F100E297601}.Release.Build.0 = Release|.NET
	EndGlobalSection
	GlobalSection(ExtensibilityGlobals) = postSolution
	EndGlobalSection
	GlobalSection(ExtensibilityAddIns) = postSolution
	EndGlobalSection
EndGlobal

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
Architect Kudzu Interactive
United States United States
Brian Duke is the VP of Tech Ops for iHealth Technologies and enjoys staying active in development whenever he can.

Comments and Discussions