I
I
iluxa18102016-05-22 20:43:22
.NET
iluxa1810, 2016-05-22 20:43:22

How to get all Access database tables except hidden ones?

Can you tell me how can I get a list of all tables excluding hidden ones?

restrictions[3] = "Table";
                DataTable tables = conn.GetOleDbSchemaTable(OleDbSchemaGuid.Tables, restrictions);

Returns all tables to me, including hidden user tables, even though I don't need it.
How can I achieve the result I want?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
Николай, 2016-05-22
@M0zart

Можно попробовать посылать такой запрос к БД Access:

SELECT MSysObjects.Name AS table_name, *
FROM MSysObjects
WHERE Left([Name],1)<>"~"
        AND Left([Name],4)<>"MSys"
        AND MSysObjects.Type In (1,4,6)
order by MSysObjects.Name

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question