Define OleDbConnection - what? how? thought it was.

I have a form with 3 lablels on it and one text box and one button.
I have made connections to the database using the Data Connection wizzards so now I have an OleDbDataAdapter, OleDbConnection, and DataSet....not sure if that matters but...
When I use the following code in my VB.NET project it underlines OleDbConnection, OleDbCommand  and OleDbDataReader saying "Type OleDbCommand is not defined"
What Do I need to do to define them to get this code to work?


   Dim Connection As OleDbConnection = New OleDbConnection(YourConStr)
        Dim Command As OleDbCommand = New OleDbCommand("SELECT SocSecNo FROM CustomerMaster WHERE SocSecNo='" & txtSocNo.Text & "' AND LastActiveDate BETWEEN '" & Now() & "' AND '" & Now() - 5, Connection)
        Dim DataReader As OleDbDataReader

        DataReader = Command.ExecuteReader
        If DataReader.Read() Then
            'Data Found Display in Labels here
            lblFirstName.Text = DataReader("FirstName")
            lblLastName.Text = DataReader("LastName")
            lblSoc.Text = DataReader("SocSecNo")
            'No data for the Particular Social ID
            'Either Empty the labels or leave it as it is
            lblFirstName.Text = ""
            lblLastName.Text = ""
            lblSoc.Text = ""
        End If
Would this be my connection string (YourConStr)

        Me.OleDbConnection1.ConnectionString = "Jet OLEDB:Registry Path=;Data Source=""C:\Program Files\My APP\DlrData.mdb"" & _
        ";Jet OLEDB:System database=;Jet OLEDB:Global Bulk Transactions=1;Jet OL" & _
        "EDB:Don't Copy Locale on Compact=False;User ID=Admin;Provider=""Microsoft.Jet.OLE" & _
        "DB.4.0"";Jet OLEDB:Database Locking Mode=0;Jet OLEDB:SFP=False;Jet OLEDB:Encrypt " & _
        "Database=False;Jet OLEDB:Create System Database=False;Jet OLEDB:Compact Without " & _
        "Replica Repair=False;Jet OLEDB:Global Partial Bulk Ops=2;Mode=Share Deny None;Ex" & _
        "tended Properties=;Jet OLEDB:Engine Type=4"
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Jeff CertainCommented:
You need to add the line Imports System.Data.OLEDb at the very beggining of your code.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Visual Basic.NET

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.