How to connect to microsoft access, foxpro , oracle etc?, DOT NET Programming

How can we connect to Microsoft Access, Foxpro , Oracle etc ?

The Microsoft provides System.Data.OleDb namespace to communicate with the databases such as Oracle, scessĀ  etc. In brief any OLE DB-Compliant database can be connected using the System.Data.OldDb namespace.

Private Sub loadData()

Dim strPath As String

strPath = AppDomain.CurrentDomain.BaseDirectory

Dim objOLEDBCon As New OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data Source =" & strPath & "Nwind.mdb")

Dim objOLEDBCommand As OleDbCommand Dim objOLEDBReader As OleDbDataReader Try

objOLEDBCommand = New OleDbCommand("Select FirstName from Employees")

objOLEDBCon.Open() objOLEDBCommand.Connection = objOLEDBCon objOLEDBReader = objOLEDBCommand.ExecuteReader() Do While objOLEDBReader.Read()

lstNorthwinds.Items.Add(objOLEDBReader.GetString(0)) Loop

Catch ex As Exception

Throw ex

Finally objOLEDBCon.Close()

End Try

End Sub

Posted Date: 9/24/2012 2:28:53 AM | Location : United States







Related Discussions:- How to connect to microsoft access, foxpro , oracle etc?, Assignment Help, Ask Question on How to connect to microsoft access, foxpro , oracle etc?, Get Answer, Expert's Help, How to connect to microsoft access, foxpro , oracle etc? Discussions

Write discussion on How to connect to microsoft access, foxpro , oracle etc?
Your posts are moderated
Related Questions
I have a code in C# which uses Microsoft Solver Foundation to solve linear programming model. But the problem is the code is too long, there are too many variables and constraints,

What do you understand by SOAP encoding? The Serialization of the types, such as integers and strings, inside a SOAP message is known as encoding. The SOAP objects use XML elem

Consumer and Dealer management Project Description: Need to code the existing UI for relative and CRUD automation. Prepare CRUD for almost 7-10 forms with search and repor

What is the relationship between a class and an object? A class acts as a blue-print that explains the properties, states, and behaviors that are common to a number of objects.

How do we access attributes using "XmlReader"? The below snippets represents the way to access attributes. At First in order to check whether there any attributes present in th

What is three tier architecture? The 3 tier software architecture was comes into action in the 1990s to overcome the limitations of the 2 tier architecture. There are 3 laye

what are major difference between classic ADO &ADO.NET?

Project Description: My project is to construct for me an application that emulates the http requests made in a webapp. It will need a lot of dedication and skill in C#,.net,

What is black box testing & White box testing? The Black box testing is also termed as functional testing. It ignores how the internal functionality of a system works & depends

Describe the various components in sequence diagrams. Object lifeline: - It shows the lifetime of an object creation and its destruction. If the object is created or des