Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

Welcome to the new platform of Programmer's Heaven! We apologize for the inconvenience caused, if you visited us from a broken link of the previous version. The main reason to move to a new platform is to provide more effective and collaborative experience to you all. Please feel free to experience the new platform and use its exciting features. Contact us for any issue that you need to get clarified. We are more than happy to help you.

Index foxpro table using VB.NET

makdumakdu Posts: 2Member
Hi,
I have a visual foxpro table. I want to index the table from vb.net and use that indexed table for the application.

I want to achieve the same result in vb.net which is obtained from foxpro.

In foxpro, the commands used are

[Code]
use invent
index on item_no to itmnoThe equivalent i tried to use in vb.net is
[/code]
[Code]
cn = New System.Data.OleDb.OleDbConnection("Provider=VFPOLEDB.1;Data Source=D:atitest;Persist Security Info=False")
cn.Open()
Dim Query1 As String = "use INVENT"
Dim Query2 As String = "index on item tag itemindx"
Dim Cmd1 As OleDbCommand = New OleDbCommand(Query1, cn)
Dim Cmd2 As OleDbCommand = New OleDbCommand(Query2, cn)
Cmd1.ExecuteNonQuery()
Cmd2.ExecuteNonQuery()I am getting exception in Cmd2.ExecuteNonQuery()
[/code]

[HTML]
One or more errors occurred during processing of command[/html]
Sign In or Register to comment.