Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

issue with docmd.transfertext and my status/progress bar

Status
Not open for further replies.

thevillageinn

Technical User
Feb 28, 2002
124
US
I am having a really hard time wrapping my head around how to update my status bar while I am running the transfertext command.

Can any one help?

I have a status bar and a pop-up form and it works when I have an incremental value to pass it, but I don't know how to get Access to either pass it's own status bar value, or how I could get an incremental variable from one transfer text command?

The piece of code I'm running is this...
Code:
DoCmd.TransferText acImportFixed, "File Import Specification", "Table", FileName1, False, ""

The other problem is that the file I import varies in size from 1mb up to somewhere near 100mb. So I can't just assign a timer and a value with that either.

I'm confused.

Thanks for any assistance.
-Dan
 
I don't think you can "control" a Status bar whilst using this type of Import. If the System Status bar is visible then Access will update the progress as it does with long running queries.

Alternatively you could use code to keep users in touch with the progress. I use this method when importing some large text files (usually several hundred thousand lines) which are of variable size. However I read these in a line at a time which is not what you are doing. Post a reply if you're interested in loking at this code. Sandy
 
Sandy,
Thanks for your reply. I was afraid I wouldn't be able to increment or interact with my progress bar using the command I am.

I have thought about reading the files in line by line, is that very slow? In my case the files range up to around 100k lines per file, and the table once the import is finished usually ranges somewhere between 500k and 1000k records.

I would like to see a sample of your code if you don't mind posting it. Thanks again-
-Dan
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top