Advertisement

06.06.2007 at 02:39PM PDT, ID: 22617644
[x]
Attachment Details

Showing a progress bar with oledbadapter.fill (VB.net)

Asked by NeutronRon in .NET, Miscellaneous Programming, Visual Basic Programming

Tags: progress, bar

I am using the oledbadapter.fill function to import large .csv files into a VB.net DataTable and would like to show a progress bar.

        Dim sConnectionString As String = "Provider=Microsoft.Jet.OLEDB.4.0;Extended Properties=Text;Data Source=" & file.DirectoryName
        Dim objConn As New OleDbConnection(sConnectionString)
        objConn.Open()
        Dim OleDbString As String = "SELECT * FROM [" & file.Name & "]"
        Dim objCmdSelect As New OleDbCommand(OleDbString, objConn)
        Dim objAdapter1 As New OleDbDataAdapter
        Dim objDataset1 As New DataSet

        objAdapter1.SelectCommand = objCmdSelect
        objAdapter1.Fill(objDataset1, "SourceData")
        dTable = objDataset1.Tables(0)
        dTable.TableName = SOURCE_TABLE_NAME

        objConn.Close()

Is there any way to monitor the progress of this operation and show it in a progress bar?  (e.g. Does the fill() raise progress events?

Start Free Trial
[+][-]06.06.2007 at 06:47PM PDT, ID: 19229884

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]06.07.2007 at 06:04AM PDT, ID: 19233033

View this solution now by starting your 7-day free trial. Setting up your free trial is quick, easy, and secure. We will return you to this solution, unlocked, when you're done.

 

About this solution

Zones: .NET, Miscellaneous Programming, Visual Basic Programming
Tags: progress, bar
Sign Up Now!
Solution Provided By: iboutchkine
Participating Experts: 2
Solution Grade: A
 
 
[+][-]06.07.2007 at 10:48PM PDT, ID: 19239824

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]07.01.2007 at 08:21AM PDT, ID: 19399256

Experts Exchange has a courteous staff of administrators who help members get the most out of the website by means of administrative comments like this one.

Start your 7-day free trial to view this Administrative Comment or ask the Experts your question.

 
 
Loading Advertisement...
20080716-EE-VQP-32