Linking a picture to a value in a combo box?

  • Thread starter Thread starter jtracy
  • Start date Start date
J

jtracy

Guest
Hey all,

Using access 97

Is this possible? I have a combo box with 4-5 values entered..and would like to somehow have an image load when a particular value is selected-one picture for each value.

Thanks for any help!
 
In the afterupdate event of your combobox use something like this:

Private Sub Combo1_AfterUpdate()
Select Case Me!Combo1
Case Is = 1
Me!Image0.Picture = "PatchandNameofImage1"
Case Is = 2
Me!Image0.Picture = "PatchandNameofImage2"
Case Is = 3
Me!Image0.Picture = "PatchandNameofImage3"
Case Is = 4
Me!Image0.Picture = "PatchandNameofImage4"
Case Is = 5
Me!Image0.Picture = "PatchandNameofImage5"
End Select
End Sub
 

Users who are viewing this thread

Back
Top Bottom