Click here to Skip to main content
16,008,183 members
Home / Discussions / Visual Basic
   

Visual Basic

 
AnswerRe: vb.net - Show the name of Table and Fields in DB Ms access Pin
Eddy Vluggen24-Jan-12 5:13
professionalEddy Vluggen24-Jan-12 5:13 
GeneralRe: vb.net - Show the name of Table and Fields in DB Ms access Pin
Mangore7524-Jan-12 11:47
Mangore7524-Jan-12 11:47 
QuestionRe: vb.net - Show the name of Table and Fields in DB Ms access Pin
Eddy Vluggen24-Jan-12 12:03
professionalEddy Vluggen24-Jan-12 12:03 
AnswerRe: vb.net - Show the name of Table and Fields in DB Ms access Pin
Wes Aday23-Jan-12 11:28
professionalWes Aday23-Jan-12 11:28 
GeneralRe: vb.net - Show the name of Table and Fields in DB Ms access Pin
Mangore7524-Jan-12 3:34
Mangore7524-Jan-12 3:34 
AnswerRe: vb.net - Show the name of Table and Fields in DB Ms access Pin
Eddy Vluggen24-Jan-12 12:42
professionalEddy Vluggen24-Jan-12 12:42 
GeneralRe: vb.net - Show the name of Table and Fields in DB Ms access Pin
Mangore7525-Jan-12 3:49
Mangore7525-Jan-12 3:49 
AnswerRe: vb.net - Show the name of Table and Fields in DB Ms access Pin
Eddy Vluggen25-Jan-12 8:55
professionalEddy Vluggen25-Jan-12 8:55 
Mangore75 wrote:
it showed me msgbox but there is no any of name tables.

That's why I explained how to use the debugger. Seriously, put the cursor on the line that contains the MessageBox, hit the F9 key and F5. Once the IDE shows up again, your application will be halted on the line with the breakpoint, allowing you to inspect the contents of the variable. That's a lot more effective that looking at things through a MsgBox.

On to your problem; the code should work. Download the Northwind[^]-example and test the code below (with the complete path to your database);
VB.NET
        Dim dt As DataTable
        Using con As New OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;" & _
"Data Source =""C:\Users\Eddy\Desktop\NWind.mdb""")
            con.Open()
            dt = con.GetSchema("TABLES")
        End Using

        For Each row As DataRow In dt.Rows
            Console.WriteLine(row("TABLE_NAME"))
        Next
        Console.WriteLine()

Bastard Programmer from Hell Suspicious | :suss:

AnswerRe: vb.net - Show the name of Table and Fields in DB Ms access Pin
Luc Pattyn23-Jan-12 11:30
sitebuilderLuc Pattyn23-Jan-12 11:30 
QuestionI want to learn about VB.net. Pin
johnskymoon23-Jan-12 10:25
johnskymoon23-Jan-12 10:25 
AnswerRe: I want to learn about VB.net. Pin
Eddy Vluggen23-Jan-12 11:03
professionalEddy Vluggen23-Jan-12 11:03 
AnswerRe: I want to learn about VB.net. Pin
Luc Pattyn25-Jan-12 6:19
sitebuilderLuc Pattyn25-Jan-12 6:19 
GeneralRe: I want to learn about VB.net. Pin
Eddy Vluggen25-Jan-12 6:47
professionalEddy Vluggen25-Jan-12 6:47 
AnswerRe: I want to learn about VB.net. Pin
ag9911001124-Jan-12 7:51
ag9911001124-Jan-12 7:51 
AnswerRe: I want to learn about VB.net. Pin
Clark Kent12325-Jan-12 5:16
professionalClark Kent12325-Jan-12 5:16 
GeneralRe: I want to learn about VB.net. Pin
Framework .l.26-Jan-12 17:37
Framework .l.26-Jan-12 17:37 
AnswerRe: I want to learn about VB.net. Pin
thatraja26-Jan-12 19:54
professionalthatraja26-Jan-12 19:54 
Questionmulti-language Pin
C#Coudou22-Jan-12 22:26
C#Coudou22-Jan-12 22:26 
AnswerRe: multi-language Pin
Eddy Vluggen23-Jan-12 0:19
professionalEddy Vluggen23-Jan-12 0:19 
AnswerRe: multi-language Pin
thatraja23-Jan-12 2:46
professionalthatraja23-Jan-12 2:46 
QuestionIs a workbook open? Pin
Fred Andres22-Jan-12 8:03
Fred Andres22-Jan-12 8:03 
AnswerRe: Is a workbook open? Pin
David Mujica23-Jan-12 3:40
David Mujica23-Jan-12 3:40 
GeneralRe: Is a workbook open? Pin
Fred Andres23-Jan-12 5:22
Fred Andres23-Jan-12 5:22 
GeneralRe: Is a workbook open? Pin
David Mujica27-Jan-12 6:55
David Mujica27-Jan-12 6:55 
SuggestionI would like to implement a before/after images Pin
krruertyret22-Jan-12 6:58
krruertyret22-Jan-12 6:58 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.