Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / Modules / DAO / VBA / January 2007

Tip: Looking for answers? Try searching our database.

Access and Photos

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Leonard - 15 Jan 2007 05:40 GMT
Hi

I have a form that displays a photo for each student. This is done through
storing the path of the photo in a table and displaying the photo when on
current (ie)

me.imgName.picture=me.imgpath

Each photo is downsized to about 7kb so all works well unless a user keeps
pressing the next record button. In some cases this causes access to crash as
it can't keep up with opening the photos to the current record.

Is there a way to stop the user going to the next record until the current
photo is displayed?

Many thanks

Leonard
Australia
Jesper - 15 Jan 2007 23:28 GMT
> Is there a way to stop the user going to the next record until the current
> photo is displayed?

A way is to use your own buttons for Next, Previous etc. and then disable
them very briefly until the image i loaded and reenable them then.

/ Jesper
Leonard - 16 Jan 2007 04:40 GMT
Hi Jesper

Thanks for that. The next and previous buttons are ones I made. How do I
tell if Access is finished loading the photo?

Thanks

Leonard
Australia

> > Is there a way to stop the user going to the next record until the current
> > photo is displayed?
[quoted text clipped - 3 lines]
>
> / Jesper
Jesper - 16 Jan 2007 16:27 GMT
>> > Is there a way to stop the user going to the next record until the
>> > current
>> > photo is displayed?
>>
>> A way is to use your own buttons for Next, Previous etc. and then disable
>> them very briefly until the image i loaded and reenable them then.

I think I've used this on the click events of the next and prev. buttons:
(note that you'll have to move focus somewhere while the button is
disabled).

Me!cmdNextButton.enabled=false
Me!cmdPreviousButton.enabled=false

Me!yourimagecontrol.picture = pathtoimage

Me!cmdNextButton.enabled=true
Me!cmdPreviousButton.enabled=true

would that work?

/ Jesper
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.