Last active
August 29, 2015 13:57
-
-
Save groggi/d14903f286f45a21110b to your computer and use it in GitHub Desktop.
Prints out all OLE DB Providers. Don't forget that some are only available if you run 32 or 64 Bit applications
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Data.OleDb; | |
namespace OleDbEnum | |
{ | |
class Program | |
{ | |
static void Main(string[] args) | |
{ | |
var reader = OleDbEnumerator.GetRootEnumerator(); | |
while(reader.Read()) | |
{ | |
for (int i = 0; i < reader.FieldCount; i++) | |
{ | |
Console.WriteLine("{0}: {1}", reader.GetName(i), reader.GetValue(i)); | |
} | |
Console.WriteLine(); | |
} | |
Console.ReadLine(); | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment