1

Konu: fox table si açık mı ?

C #  ' da
DataSet ds = new DataSet();
OleDbConnection baglanti = new OleDbConnection();
baglanti.ConnectionString = "Provider=VFPOLEDB.1;Data Source=C:\\enabiz.dbf";
baglanti.Open();

..
....

şeklinde açılan bir fox table sinin açık olup olmadığını nasıl anlarım ?

2

Re: fox table si açık mı ?

C#
DataSet ds = new DataSet(); 

 
string connectionString = @"Provider=VFPOLEDB.1;Data Source=c:\";
string cmdText = "select * from enabiz";
 
OleDbDataAdapter adapter = new OleDbDataAdapter(cmdText, connectionString);
try
{           
  adapter.Fill(ds,"Enabiz"); 
}
catch (Exception ex)
{
    Console.WriteLine (ex.Message);
}

3

Re: fox table si açık mı ?

Çok sağol Çetin.

smile
Yapmıştım onu zaten.


gereksiz yere
lnHandle = Fopen('tableadi.dbf',12)
If lnHandle < 0
    Wait Window " dosyayı kapatın" Timeout(4)
    Quit
Endif

gibi başlangıçta kontrol yapmam gerekir  gibi garip bir mantık kurdum..