SetFocus to Image Control..

B

Brett Davis

Hello...

I am having a hard time trying to setfocus to an image control. every time
i attempt to setfocus i get the following error: Can't move the focus to
the control Image1.

I am using the following code:
Me!Image1.Setfocus

If I try the full qualified path of:
Forms!Form1!Image1.SetFocus

Both fail. I am using Access 2000. It is interesting that in Microsoft
Visual Basic it allows you to select SetFocus from the drop down but does
not allow me to setfocus to the image when i try to open the form.

Any help would be much appreciated.

Thank you,

Brett
 
R

Rob Parker

An image control simply displays an image; it does not accept any user
input. It therefore cannot gain focus - evidenced by the fact that there is
no OnGotFocus event for an image control.

Why do you want to set focus to the image control?

You can display an image in a bound or unbound object frame if you must set
focus to it for some reason; these controls do accept focus.

HTH,

Rob
 

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