Slowing Record Navigation

D

Dewey

I have an inventory form that displays a linked photo for each inventory
item. The file path for each item's photo is stored in a hidden text field
and as the user moves from record to record, the OnCurrent property of the
form triggers an update to the image frame. My problem is, the database will
crash if users move too quickly between records. I have removed the Access
navigation buttons and inserted my own, but I'm unsure how to force a
half-second pause after each record selection. I'd certainly appreciate any
ideas on the matter.
 
P

PC Datasheet

The image file of each item is relatively large and takes time to load when
you go to another record. Remove the code in the Oncurrent event that laods
each image. Rather, put a button "Show Photo Of Item" under the image
control and put your code to load the image in the Click event of the
button. The users will then be able to quickly navigate through the item
records and when they get to the one they are looking for, they can load the
photo of the item if they wish.

--
PC Datasheet
Your Resource For Help With Access, Excel And Word Applications
(e-mail address removed)
www.pcdatasheet.com

If you don't get the help you need in the newsgroup, I can help you for a
very reasonable fee. Over 1000 Access users have come to me for help.
 
G

George Nicholson

You could try adding a "DoEvents" line to your OnCurrent code. That >might<
allow the picture loading process the opportunity to catch up with record
selection.

HTH,
 
B

bob

Four options spring to mind:

1) Suppress the loading dialog:
http://www.mvps.org/access/api/api0038.htm
This requires a registry key modification on each user’s machine.

2) Only display the image ‘on demand’, eg using a ‘show image’ button, a different tab or a modal popup
window.

3) Slow navigation using a timer, but this rather interferes with the usability of the forms, and assumes
a fixed maximum image decode time, which must therefore be generous.

4) Use a third party control.
 
D

Dewey

Thanks to all. The reason I'm displaying an image with each inventory item
(I should have mentioned earlier) is because employees have a difficult time
identifying them by name alone. I think a 500 millisecond delay would be
sufficient for each image to load... Would I need to make each record load
with the navigation buttons disabled and then enable them with the On Timer
event?
 
S

Stephen Lebans

If you modify the Registry as Bob mentioned to stop the display of the
"loading Image" dialog then you will no longer crash as you scroll through
the records.

--

HTH
Stephen Lebans
http://www.lebans.com
Access Code, Tips and Tricks
Please respond only to the newsgroups so everyone can benefit.
 
D

Dewey

I tried the registry modification and it appears to have solved the problem.

Thanks so much for the help!
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top