Ureader.com  
Microsoft software help and Community
   home   |   control panel login   |   archive   |  
 
DotNet
acad.assignment.mngr
academic
adonet
aspnet
aspnet.announcements
aspnet.build.controls
aspnet.caching
aspnet.datagridcontrol
aspnet.mobile
aspnet.security
aspnet.webcontrols
aspnet.webservices
clr
compactframework
component_services
datatools
distributed_apps
drawing
faqs
framework
framework.wmi
general
internationalization
interop
languages.csharp
languages.jscript
languages.vb
languages.vb.controls
languages.vb.data
languages.vb.upgrade
languages.vc
languages.vc.libraries
myservices
odbcnet
performance
remoting
scripting
sdk
security
setup
vjsharp
vsa
webservi.enhancements
webservices
windowsforms
windowsforms.controls
winforms.databinding
winforms.designtime
xml
  
 
date: Sun, 9 Apr 2006 04:47:01 -0700,    group: microsoft.public.dotnet.datatools        back       


How to use dbf file in Data Adapter Configuration Wizard   
I am learning to use ADO.Net. I want to connect a dbf file (FoxPro).  I tried 
following ways without success to use dbf file for my database application.

Using Data Adapter Configuration Wizard (with OleDBAdapter);

1) while connecting dbf file with Microsoft Jet 4.0 OleDB provider it says   
"connection  failed.......initialiasing provider.......unrecognised 
format.....customer.dbf "

2) while connecting dbf file with Microsoft OLE DB provider for ODBC drivers 
the Test connection says "Successful" but on the next click on Wizard the 
error appear is "The connection you have created does not work with the 
currect adapter"

I have already installed latest version of MDAC 8.0, ODBC.Net Data Provider 
and JET 4.0 Service Pack 8 but I am still not able to use dbf file as above. 
Please help me. 

Thank you,
Rakesh
date: Sun, 9 Apr 2006 04:47:01 -0700   author:   Rakesh Parekh Rakesh

Re: How to use dbf file in Data Adapter Configuration Wizard   
Hi Rakesh,

Your "unrecognized format" error is most likely due to the version of Visual 
FoxPro the Customer table was created with being incompatible with the Jet 
OLE DB data provider.

The Jet OLE DB data provider won't work with all versions of FoxPro tables. 
It will only work with DBFs that have been created with FoxPro 2.6 for 
Windows and earlier. Visual FoxPro is now in version VFP9 and even though 
the FoxPro ODBC drivers work with all VFP6 and earlier tables, tables 
created with data features added after VFP6 will only work with the Visual 
FoxPro OLE DB data provider.

Please try the FoxPro and Visual FoxPro OLE DB data provider, downloadable 
from msdn.microsoft.com/vfoxpro/downloads/updates.

-- 
Cindy Winegarden  MCSD, Microsoft Visual FoxPro MVP
cindy_winegarden@msn.com  www.cindywinegarden.com


"Rakesh Parekh" <Rakesh Parekh@discussions.microsoft.com> wrote in message 
news:D540A6CB-73C6-41B8-B39C-FF8383DA8317@microsoft.com...
>I am learning to use ADO.Net. I want to connect a dbf file (FoxPro).  I 
>tried
> following ways without success to use dbf file for my database 
> application.
>
> Using Data Adapter Configuration Wizard (with OleDBAdapter);
>
> 1) while connecting dbf file with Microsoft Jet 4.0 OleDB provider it says
> "connection  failed.......initialiasing provider.......unrecognised
> format.....customer.dbf "
>
> 2) while connecting dbf file with Microsoft OLE DB provider for ODBC 
> drivers
> the Test connection says "Successful" but on the next click on Wizard the
> error appear is "The connection you have created does not work with the
> currect adapter"
>
> I have already installed latest version of MDAC 8.0, ODBC.Net Data 
> Provider
> and JET 4.0 Service Pack 8 but I am still not able to use dbf file as 
> above.
> Please help me.
>
> Thank you,
> Rakesh
>
date: Sun, 9 Apr 2006 17:11:17 -0400   author:   Cindy Winegarden

Re: How to use dbf file in Data Adapter Configuration Wizard   
Dear Cindy,

Thanks for the prompt response. One correction in my original post. The dbf 
file I use is generated through a DOS base application FoxPro 2.6. It is not 
Visual FoxPro. I have already downloaded and installed the update for ForPro 
you suggested but it is still not working. 

I can successfully use these dbf files for creating database pages using 
FrontPage 2003 and there is absolutely no problem. Pls advise how can I use 
DOS base FoxPro generated dbf file in ADO.Net.

Thanks again for prompt response,
Rakesh

"Cindy Winegarden" wrote:

> Hi Rakesh,
> 
> Your "unrecognized format" error is most likely due to the version of Visual 
> FoxPro the Customer table was created with being incompatible with the Jet 
> OLE DB data provider.
> 
> The Jet OLE DB data provider won't work with all versions of FoxPro tables. 
> It will only work with DBFs that have been created with FoxPro 2.6 for 
> Windows and earlier. Visual FoxPro is now in version VFP9 and even though 
> the FoxPro ODBC drivers work with all VFP6 and earlier tables, tables 
> created with data features added after VFP6 will only work with the Visual 
> FoxPro OLE DB data provider.
> 
> Please try the FoxPro and Visual FoxPro OLE DB data provider, downloadable 
> from msdn.microsoft.com/vfoxpro/downloads/updates.
> 
> -- 
> Cindy Winegarden  MCSD, Microsoft Visual FoxPro MVP
> cindy_winegarden@msn.com  www.cindywinegarden.com
> 
> 
> "Rakesh Parekh" <Rakesh Parekh@discussions.microsoft.com> wrote in message 
> news:D540A6CB-73C6-41B8-B39C-FF8383DA8317@microsoft.com...
> >I am learning to use ADO.Net. I want to connect a dbf file (FoxPro).  I 
> >tried
> > following ways without success to use dbf file for my database 
> > application.
> >
> > Using Data Adapter Configuration Wizard (with OleDBAdapter);
> >
> > 1) while connecting dbf file with Microsoft Jet 4.0 OleDB provider it says
> > "connection  failed.......initialiasing provider.......unrecognised
> > format.....customer.dbf "
> >
> > 2) while connecting dbf file with Microsoft OLE DB provider for ODBC 
> > drivers
> > the Test connection says "Successful" but on the next click on Wizard the
> > error appear is "The connection you have created does not work with the
> > currect adapter"
> >
> > I have already installed latest version of MDAC 8.0, ODBC.Net Data 
> > Provider
> > and JET 4.0 Service Pack 8 but I am still not able to use dbf file as 
> > above.
> > Please help me.
> >
> > Thank you,
> > Rakesh
> > 
> 
> 
>
date: Tue, 11 Apr 2006 02:18:02 -0700   author:   Rakesh Parekh

Re: How to use dbf file in Data Adapter Configuration Wizard   
Hi Rakesh,

If the files are FPD2.6 then they should be readable via Jet or via the 
FoxPro and Visual FoxPro OLE DB data provider, since it's 
backward-compatible for all Fox versions.

What exactly does your connection string look like? What code are you using 
to access the tables?

-- 
Cindy Winegarden  MCSD, Microsoft Visual FoxPro MVP
cindy_winegarden@msn.com  www.cindywinegarden.com


"Rakesh Parekh"  wrote in message 
news:619CC42E-9AEE-4521-8F1D-41023D54645D@microsoft.com...
>... The dbf
> file I use is generated through a DOS base application FoxPro 2.6. It is 
> not
> Visual FoxPro. I have already downloaded and installed the update for 
> ForPro
> you suggested but it is still not working.
>
> I can successfully use these dbf files for creating database pages using
> FrontPage 2003 and there is absolutely no problem. Pls advise how can I 
> use
> DOS base FoxPro generated dbf file in ADO.Net.

>> > Using Data Adapter Configuration Wizard (with OleDBAdapter);
>> >
>> > 1) while connecting dbf file with Microsoft Jet 4.0 OleDB provider it 
>> > says
>> > "connection  failed.......initialiasing provider.......unrecognised
>> > format.....customer.dbf "
>> >
>> > 2) while connecting dbf file with Microsoft OLE DB provider for ODBC
>> > drivers
>> > the Test connection says "Successful" but on the next click on Wizard 
>> > the
>> > error appear is "The connection you have created does not work with the
>> > currect adapter"
date: Tue, 11 Apr 2006 11:49:40 -0400   author:   Cindy Winegarden

Re: How to use dbf file in Data Adapter Configuration Wizard   
Dear Cindy,

It works fine when I use following connection. 

MyConnection = New 
Microsoft.Data.Odbc.OdbcConnection("Provider=MSDASQL;DSN=mydBase")

But I do not want to use a DSN. Instead I want to use a server path like

" \\fpdb\booking.dbf "

How do I tell the connection to refer server path "\\fpdb\booking.dbf" and 
where do I put it?. Pls advise. 

Thank you,
Rakesh


"Cindy Winegarden" wrote:

> Hi Rakesh,
> 
> If the files are FPD2.6 then they should be readable via Jet or via the 
> FoxPro and Visual FoxPro OLE DB data provider, since it's 
> backward-compatible for all Fox versions.
> 
> What exactly does your connection string look like? What code are you using 
> to access the tables?
> 
> -- 
> Cindy Winegarden  MCSD, Microsoft Visual FoxPro MVP
> cindy_winegarden@msn.com  www.cindywinegarden.com
> 
> 
> "Rakesh Parekh"  wrote in message 
> news:619CC42E-9AEE-4521-8F1D-41023D54645D@microsoft.com...
> >... The dbf
> > file I use is generated through a DOS base application FoxPro 2.6. It is 
> > not
> > Visual FoxPro. I have already downloaded and installed the update for 
> > ForPro
> > you suggested but it is still not working.
> >
> > I can successfully use these dbf files for creating database pages using
> > FrontPage 2003 and there is absolutely no problem. Pls advise how can I 
> > use
> > DOS base FoxPro generated dbf file in ADO.Net.
> 
> >> > Using Data Adapter Configuration Wizard (with OleDBAdapter);
> >> >
> >> > 1) while connecting dbf file with Microsoft Jet 4.0 OleDB provider it 
> >> > says
> >> > "connection  failed.......initialiasing provider.......unrecognised
> >> > format.....customer.dbf "
> >> >
> >> > 2) while connecting dbf file with Microsoft OLE DB provider for ODBC
> >> > drivers
> >> > the Test connection says "Successful" but on the next click on Wizard 
> >> > the
> >> > error appear is "The connection you have created does not work with the
> >> > currect adapter"
> 
> 
>
date: Fri, 14 Apr 2006 04:51:01 -0700   author:   Rakesh Parekh

Re: How to use dbf file in Data Adapter Configuration Wizard   
Hi Rakesh,

Since you're working in a .NET language it's time to get away from ODBC, 
which is a deprecated data access technology. The FoxPro and Visual FoxPro 
OLE DB data provider will work correctly with all Fox tables. Since you're 
using FPD 2.6 tables your connection string should point to the directory 
where the tables are. Then you can use code like this:

'-- -------------------------------------------
Imports System
Imports System.Data
Imports System.Data.OleDb

Module Module1

    Sub Main()

        Dim cn As New OleDbConnection( _
                     "Provider=VFPOLEDB.1;Data Source=C:\Temp\;")
        cn.Open()

        Dim cmd1 As New OleDbCommand( _
            "Create Table TestDBF (Field1 C(10))", cn)
        Dim cmd2 As New OleDbCommand( _
            "Insert Into TestDBF Values ('Hello')", cn)
        Dim cmd3 As New OleDbCommand( _
            "Insert Into TestDBF Values ('World')", cn)
        cmd1.ExecuteNonQuery()
        cmd2.ExecuteNonQuery()
        cmd3.ExecuteNonQuery()
        Dim cmd4 As New OleDbCommand("Select * From TestDBF", cn)
        Dim r1 As OleDbDataReader = cmd4.ExecuteReader()
        Dim Field1Data As String = ""
        While r1.Read()
           Field1Data += r1.GetString(0) + vbCrLf
        End While

        MsgBox(Field1Data.ToString())

        r1.Close()
        cn.Close()

    End Sub

End Module
'-- -------------------------------------------


-- 
Cindy Winegarden  MCSD, Microsoft Visual FoxPro MVP
cindy_winegarden@msn.com  www.cindywinegarden.com


"Rakesh Parekh"  wrote in message 
news:937476CB-68AD-4ADA-931B-9610688901F6@microsoft.com...
> Dear Cindy,
>
> It works fine when I use following connection.
>
> MyConnection = New
> Microsoft.Data.Odbc.OdbcConnection("Provider=MSDASQL;DSN=mydBase")
>
> But I do not want to use a DSN. Instead I want to use a server path like
>
> " \\fpdb\booking.dbf "
>
> How do I tell the connection to refer server path "\\fpdb\booking.dbf" and
> where do I put it?. Pls advise.
date: Sat, 15 Apr 2006 17:57:09 -0400   author:   Cindy Winegarden

Re: How to use dbf file in Data Adapter Configuration Wizard   
Dear Cindy,

Thank you for quick response. Ok I now understand that I don't have to use 
ODBC. I have a few questions.

1) Is the Provider "VFPOLEDB" common for DOS BASE applicaiton FoxPro 2.6 and 
Visual Fox Pro? Is there a separate provider for FoxPro 2.6? 

2) On MSDN help "Opening a Database" I could find that it is possible to 
connect
external database using suitable Extended Properties as under:

MyConnection = New OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data 
Source=c:\BOOKING.DBF;Extended Properties=dBASE IV;")

I get an error as below with above Myconnection code 

'c:\BOOKING.DBF' is not a valid path. Make sure that the path name is spelled 
correctly and that you are connected to the server on which the file resides. 

What could be wrong? The path is absolutely correct. I also put the path on 
the 
like "servername\fpdb\booking.dbf" but it says the same error.

3) When I use Excel like

MyConnection = New OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data 
Source=c:\BOOKING.XLS;Extended Properties=Excel 3.0;")

I get error as under:

External table is not in the expected format. 

Please advise.
Thank you,
Rakesh

"Cindy Winegarden" wrote:

> Hi Rakesh,
> 
> Since you're working in a .NET language it's time to get away from ODBC, 
> which is a deprecated data access technology. The FoxPro and Visual FoxPro 
> OLE DB data provider will work correctly with all Fox tables. Since you're 
> using FPD 2.6 tables your connection string should point to the directory 
> where the tables are. Then you can use code like this:
> 
> '-- -------------------------------------------
> Imports System
> Imports System.Data
> Imports System.Data.OleDb
> 
> Module Module1
> 
>     Sub Main()
> 
>         Dim cn As New OleDbConnection( _
>                      "Provider=VFPOLEDB.1;Data Source=C:\Temp\;")
>         cn.Open()
> 
>         Dim cmd1 As New OleDbCommand( _
>             "Create Table TestDBF (Field1 C(10))", cn)
>         Dim cmd2 As New OleDbCommand( _
>             "Insert Into TestDBF Values ('Hello')", cn)
>         Dim cmd3 As New OleDbCommand( _
>             "Insert Into TestDBF Values ('World')", cn)
>         cmd1.ExecuteNonQuery()
>         cmd2.ExecuteNonQuery()
>         cmd3.ExecuteNonQuery()
>         Dim cmd4 As New OleDbCommand("Select * From TestDBF", cn)
>         Dim r1 As OleDbDataReader = cmd4.ExecuteReader()
>         Dim Field1Data As String = ""
>         While r1.Read()
>            Field1Data += r1.GetString(0) + vbCrLf
>         End While
> 
>         MsgBox(Field1Data.ToString())
> 
>         r1.Close()
>         cn.Close()
> 
>     End Sub
> 
> End Module
> '-- -------------------------------------------
> 
> 
> -- 
> Cindy Winegarden  MCSD, Microsoft Visual FoxPro MVP
> cindy_winegarden@msn.com  www.cindywinegarden.com
> 
> 
> "Rakesh Parekh"  wrote in message 
> news:937476CB-68AD-4ADA-931B-9610688901F6@microsoft.com...
> > Dear Cindy,
> >
> > It works fine when I use following connection.
> >
> > MyConnection = New
> > Microsoft.Data.Odbc.OdbcConnection("Provider=MSDASQL;DSN=mydBase")
> >
> > But I do not want to use a DSN. Instead I want to use a server path like
> >
> > " \\fpdb\booking.dbf "
> >
> > How do I tell the connection to refer server path "\\fpdb\booking.dbf" and
> > where do I put it?. Pls advise.
> 
> 
>
date: Sun, 16 Apr 2006 02:13:01 -0700   author:   Rakesh Parekh

Re: How to use dbf file in Data Adapter Configuration Wizard   
Hi Rakesh,

1. As I said below, "The FoxPro and Visual FoxPro OLE DB data provider will 
work correctly with all Fox tables."

2. As I said below, "Since you're using FPD 2.6 tables your OLE DB 
connection string should point to the directory where the tables are. Then 
you can use code like this: ....."Provider=VFPOLEDB.1;Data 
Source=C:\Temp\;")". DO NOT use the table name in the connection string. 
Only point to the directory. The place to specify the table name in a Select 
statement like: "("Select * From TestDBF", cn)" This is so you can use one 
connection string to access all of the Fox tables in that directory.

The Jet ODBC driver works with a whole bunch of different types of tables. 
Thus you need to specify the type of table (dBase IV, Excel) using the 
Extended Properties clause. If you're working with the VFPOLEDB data 
provider then you are not working with Jet. You do not use the same type of 
connection string; for example, you don't use the Extended Properties 
clause. The VFPOLEDB data provider already knows it's working with some 
version of FoxPro DBF, and it's built to figure out which version of DBF and 
go from there.

I'm not all that familiar with Jet connection strings for Excel. For your 
Excel example I see you've specified "Extended Properties=Excel 3.0;". Excel 
from Office 2003 is Excel 11 so that means Excel 3 is pretty old. Perhaps 
your tables were created with a more recent version of Excel.


-- 
Cindy Winegarden  MCSD, Microsoft Visual FoxPro MVP
cindy_winegarden@msn.com  www.cindywinegarden.com


"Rakesh Parekh"  wrote in message 
news:DE77E1F7-0DE5-4109-8B86-EE7B5605695F@microsoft.com...
> Dear Cindy,
>
> Thank you for quick response. Ok I now understand that I don't have to use
> ODBC. I have a few questions.
>
> 1) Is the Provider "VFPOLEDB" common for DOS BASE applicaiton FoxPro 2.6 
> and
> Visual Fox Pro? Is there a separate provider for FoxPro 2.6?
>
> 2) On MSDN help "Opening a Database" I could find that it is possible to
> connect
> external database using suitable Extended Properties as under:
>
> MyConnection = New OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data
> Source=c:\BOOKING.DBF;Extended Properties=dBASE IV;")
>
> I get an error as below with above Myconnection code
>
> 'c:\BOOKING.DBF' is not a valid path. Make sure that the path name is 
> spelled
> correctly and that you are connected to the server on which the file 
> resides.
>
> What could be wrong? The path is absolutely correct. I also put the path 
> on
> the
> like "servername\fpdb\booking.dbf" but it says the same error.
>
> 3) When I use Excel like
>
> MyConnection = New OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data
> Source=c:\BOOKING.XLS;Extended Properties=Excel 3.0;")
>
> I get error as under:
>
> External table is not in the expected format.
>
> Please advise.
> Thank you,
> Rakesh
>
> "Cindy Winegarden" wrote:
>
>> Hi Rakesh,
>>
>> Since you're working in a .NET language it's time to get away from ODBC,
>> which is a deprecated data access technology. The FoxPro and Visual 
>> FoxPro
>> OLE DB data provider will work correctly with all Fox tables. Since 
>> you're
>> using FPD 2.6 tables your connection string should point to the directory
>> where the tables are. Then you can use code like this:
>>
>> '-- -------------------------------------------
>> Imports System
>> Imports System.Data
>> Imports System.Data.OleDb
>>
>> Module Module1
>>
>>     Sub Main()
>>
>>         Dim cn As New OleDbConnection( _
>>                      "Provider=VFPOLEDB.1;Data Source=C:\Temp\;")
>>         cn.Open()
>>
>>         Dim cmd1 As New OleDbCommand( _
>>             "Create Table TestDBF (Field1 C(10))", cn)
>>         Dim cmd2 As New OleDbCommand( _
>>             "Insert Into TestDBF Values ('Hello')", cn)
>>         Dim cmd3 As New OleDbCommand( _
>>             "Insert Into TestDBF Values ('World')", cn)
>>         cmd1.ExecuteNonQuery()
>>         cmd2.ExecuteNonQuery()
>>         cmd3.ExecuteNonQuery()
>>         Dim cmd4 As New OleDbCommand("Select * From TestDBF", cn)
>>         Dim r1 As OleDbDataReader = cmd4.ExecuteReader()
>>         Dim Field1Data As String = ""
>>         While r1.Read()
>>            Field1Data += r1.GetString(0) + vbCrLf
>>         End While
>>
>>         MsgBox(Field1Data.ToString())
>>
>>         r1.Close()
>>         cn.Close()
>>
>>     End Sub
>>
>> End Module
>> '-- -------------------------------------------
date: Mon, 17 Apr 2006 13:03:53 -0400   author:   Cindy Winegarden

Re: How to use dbf file in Data Adapter Configuration Wizard   
Hi Cindy,

You're greater than the greatest and I'm happier than the happiest. It 
solved all my problems and I can now use both Jet and VFP provider to connect 
dBase files. 

Thanks a lot,
Rakesh


"Cindy Winegarden" wrote:

> Hi Rakesh,
> 
> 1. As I said below, "The FoxPro and Visual FoxPro OLE DB data provider will 
> work correctly with all Fox tables."
> 
> 2. As I said below, "Since you're using FPD 2.6 tables your OLE DB 
> connection string should point to the directory where the tables are. Then 
> you can use code like this: ....."Provider=VFPOLEDB.1;Data 
> Source=C:\Temp\;")". DO NOT use the table name in the connection string. 
> Only point to the directory. The place to specify the table name in a Select 
> statement like: "("Select * From TestDBF", cn)" This is so you can use one 
> connection string to access all of the Fox tables in that directory.
> 
> The Jet ODBC driver works with a whole bunch of different types of tables. 
> Thus you need to specify the type of table (dBase IV, Excel) using the 
> Extended Properties clause. If you're working with the VFPOLEDB data 
> provider then you are not working with Jet. You do not use the same type of 
> connection string; for example, you don't use the Extended Properties 
> clause. The VFPOLEDB data provider already knows it's working with some 
> version of FoxPro DBF, and it's built to figure out which version of DBF and 
> go from there.
> 
> I'm not all that familiar with Jet connection strings for Excel. For your 
> Excel example I see you've specified "Extended Properties=Excel 3.0;". Excel 
> from Office 2003 is Excel 11 so that means Excel 3 is pretty old. Perhaps 
> your tables were created with a more recent version of Excel.
> 
> 
> -- 
> Cindy Winegarden  MCSD, Microsoft Visual FoxPro MVP
> cindy_winegarden@msn.com  www.cindywinegarden.com
> 
> 
> "Rakesh Parekh"  wrote in message 
> news:DE77E1F7-0DE5-4109-8B86-EE7B5605695F@microsoft.com...
> > Dear Cindy,
> >
> > Thank you for quick response. Ok I now understand that I don't have to use
> > ODBC. I have a few questions.
> >
> > 1) Is the Provider "VFPOLEDB" common for DOS BASE applicaiton FoxPro 2.6 
> > and
> > Visual Fox Pro? Is there a separate provider for FoxPro 2.6?
> >
> > 2) On MSDN help "Opening a Database" I could find that it is possible to
> > connect
> > external database using suitable Extended Properties as under:
> >
> > MyConnection = New OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data
> > Source=c:\BOOKING.DBF;Extended Properties=dBASE IV;")
> >
> > I get an error as below with above Myconnection code
> >
> > 'c:\BOOKING.DBF' is not a valid path. Make sure that the path name is 
> > spelled
> > correctly and that you are connected to the server on which the file 
> > resides.
> >
> > What could be wrong? The path is absolutely correct. I also put the path 
> > on
> > the
> > like "servername\fpdb\booking.dbf" but it says the same error.
> >
> > 3) When I use Excel like
> >
> > MyConnection = New OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data
> > Source=c:\BOOKING.XLS;Extended Properties=Excel 3.0;")
> >
> > I get error as under:
> >
> > External table is not in the expected format.
> >
> > Please advise.
> > Thank you,
> > Rakesh
> >
> > "Cindy Winegarden" wrote:
> >
> >> Hi Rakesh,
> >>
> >> Since you're working in a .NET language it's time to get away from ODBC,
> >> which is a deprecated data access technology. The FoxPro and Visual 
> >> FoxPro
> >> OLE DB data provider will work correctly with all Fox tables. Since 
> >> you're
> >> using FPD 2.6 tables your connection string should point to the directory
> >> where the tables are. Then you can use code like this:
> >>
> >> '-- -------------------------------------------
> >> Imports System
> >> Imports System.Data
> >> Imports System.Data.OleDb
> >>
> >> Module Module1
> >>
> >>     Sub Main()
> >>
> >>         Dim cn As New OleDbConnection( _
> >>                      "Provider=VFPOLEDB.1;Data Source=C:\Temp\;")
> >>         cn.Open()
> >>
> >>         Dim cmd1 As New OleDbCommand( _
> >>             "Create Table TestDBF (Field1 C(10))", cn)
> >>         Dim cmd2 As New OleDbCommand( _
> >>             "Insert Into TestDBF Values ('Hello')", cn)
> >>         Dim cmd3 As New OleDbCommand( _
> >>             "Insert Into TestDBF Values ('World')", cn)
> >>         cmd1.ExecuteNonQuery()
> >>         cmd2.ExecuteNonQuery()
> >>         cmd3.ExecuteNonQuery()
> >>         Dim cmd4 As New OleDbCommand("Select * From TestDBF", cn)
> >>         Dim r1 As OleDbDataReader = cmd4.ExecuteReader()
> >>         Dim Field1Data As String = ""
> >>         While r1.Read()
> >>            Field1Data += r1.GetString(0) + vbCrLf
> >>         End While
> >>
> >>         MsgBox(Field1Data.ToString())
> >>
> >>         r1.Close()
> >>         cn.Close()
> >>
> >>     End Sub
> >>
> >> End Module
> >> '-- -------------------------------------------
> 
> 
> 
>
date: Tue, 18 Apr 2006 04:21:02 -0700   author:   Rakesh Parekh

Re: How to use dbf file in Data Adapter Configuration Wizard   
Hi Rakesh,

I'm glad you were successful in solving your problem.

-- 
Cindy Winegarden  MCSD, Microsoft Visual FoxPro MVP
cindy_winegarden@msn.com  www.cindywinegarden.com


"Rakesh Parekh"  wrote in message 
news:F16E4990-516F-4317-A64D-79FE947A1CA9@microsoft.com...

> You're greater than the greatest and I'm happier than the happiest. It
> solved all my problems and I can now use both Jet and VFP provider to 
> connect
> dBase files.
date: Tue, 18 Apr 2006 16:59:59 -0400   author:   Cindy Winegarden

Re: How to use dbf file in Data Adapter Configuration Wizard   
Hi Cindy,

The provider VFPOLEDB works just fine on my local machine (which is also a 
server) but when I uploaded the Web APplication on a remote site I get 
following error. What I understand from this error is that the VFPOLEDB needs 
to be installed or registered at the remote server. Is it so? How can I do 
that. I am not sure whether the service provider will do that or allow me to 
do that. Pls advise. 

No error information available: REGDB_E_CLASSNOTREG(0x80040154). 

OleDbException (0x80040154): No error information available: 
REGDB_E_CLASSNOTREG(0x80040154).]

[InvalidOperationException: The 'VFPOLEDB.1' provider is not registered on 
the local machine.]

Kind regards,
Rakesh

"Cindy Winegarden" wrote:

> Hi Rakesh,
> 
> I'm glad you were successful in solving your problem.
> 
> -- 
> Cindy Winegarden  MCSD, Microsoft Visual FoxPro MVP
> cindy_winegarden@msn.com  www.cindywinegarden.com
> 
> 
> "Rakesh Parekh"  wrote in message 
> news:F16E4990-516F-4317-A64D-79FE947A1CA9@microsoft.com...
> 
> > You're greater than the greatest and I'm happier than the happiest. It
> > solved all my problems and I can now use both Jet and VFP provider to 
> > connect
> > dBase files.
> 
> 
>
date: Sat, 22 Apr 2006 03:09:01 -0700   author:   Rakesh Parekh

Re: How to use dbf file in Data Adapter Configuration Wizard   
Hi Rakesh,

Yes, the VFP OLE DB provider will need to be installed on the server where 
the app runs. It would be installed on that machine in the same way you 
installed it on yours. If you are allowed to, you could access the remote 
server via a program like Windows XP's remote desktop and install it that 
way.

In my opinion if the service provider won't install it for you or allow you 
to install it then they are not providing very good service.

-- 
Cindy Winegarden  MCSD, Microsoft Visual FoxPro MVP
cindy_winegarden@msn.com  www.cindywinegarden.com


"Rakesh Parekh"  wrote in message 
news:DF19C401-0089-4CCE-BA0F-581C3C75B4CA@microsoft.com...

> The provider VFPOLEDB works just fine on my local machine (which is also a
> server) but when I uploaded the Web APplication on a remote site I get
> following error. What I understand from this error is that the VFPOLEDB 
> needs
> to be installed or registered at the remote server. Is it so? How can I do
> that. I am not sure whether the service provider will do that or allow me 
> to
> do that. Pls advise.
date: Sat, 22 Apr 2006 18:38:55 -0400   author:   Cindy Winegarden

Re: How to use dbf file in Data Adapter Configuration Wizard   
Dear Cindy,

I am stuck at another problem now with the query. I want to use following 
query which is not working. 

SELECT Order_No 
FROM ORDERS
WHERE Order_No LIKE "20??A##*"

I found that it works fine with Microsoft Access. What I conclude is OLE DB 
Provider for FoxPro does not support  * Or ? with LIKE. It works with LIKE 
without * or ?. Please advise. 

Thank you,
Rakesh


"Cindy Winegarden" wrote:

> Hi Rakesh,
> 
> Yes, the VFP OLE DB provider will need to be installed on the server where 
> the app runs. It would be installed on that machine in the same way you 
> installed it on yours. If you are allowed to, you could access the remote 
> server via a program like Windows XP's remote desktop and install it that 
> way.
> 
> In my opinion if the service provider won't install it for you or allow you 
> to install it then they are not providing very good service.
> 
> -- 
> Cindy Winegarden  MCSD, Microsoft Visual FoxPro MVP
> cindy_winegarden@msn.com  www.cindywinegarden.com
> 
> 
> "Rakesh Parekh"  wrote in message 
> news:DF19C401-0089-4CCE-BA0F-581C3C75B4CA@microsoft.com...
> 
> > The provider VFPOLEDB works just fine on my local machine (which is also a
> > server) but when I uploaded the Web APplication on a remote site I get
> > following error. What I understand from this error is that the VFPOLEDB 
> > needs
> > to be installed or registered at the remote server. Is it so? How can I do
> > that. I am not sure whether the service provider will do that or allow me 
> > to
> > do that. Pls advise.
> 
> 
>
date: Mon, 8 May 2006 04:26:02 -0700   author:   Rakesh Parekh

Re: How to use dbf file in Data Adapter Configuration Wizard   
Hi Rakesh,

Here's what the VFP Help says about using Like in a SQL command:


The % character represents any sequence of unknown characters in the string. 
The _ character represents a single unknown character in the string. You can 
use the ESCAPE clause to specify wildcard characters as literals.


-- 
Cindy Winegarden  MCSD, Microsoft Visual FoxPro MVP
cindy_winegarden@msn.com  www.cindywinegarden.com


"Rakesh Parekh"  wrote in message 
news:D2D1E0E7-3D12-4CFF-A49B-5822BC84A2FF@microsoft.com...

> SELECT Order_No
> FROM ORDERS
> WHERE Order_No LIKE "20??A##*"
>
> I found that it works fine with Microsoft Access. What I conclude is OLE 
> DB
> Provider for FoxPro does not support  * Or ? with LIKE. It works with LIKE
> without * or ?. Please advise.
date: Thu, 11 May 2006 17:21:15 -0400   author:   Cindy Winegarden

Google
 
Web ureader.com


    COPYRIGHT 2007, YARDI TECHNOLOGY LIMITED, ALL RIGHT RESERVE  |   contact us