My previous attempt to work around this problem (although I'm pretty sure this is NOT the way it should be done) involved creating an unbound toggle button, setting it's visibility to "No" and calling for that picture on the AfterUpdate event of the bound toggle button.
In the code, IntSypmtPain is the bound toggle button, and ToggleBlue is the unbound button that contains the picture I want to use.
Expand|Select|Wrap|Line Numbers
- Private Sub IntSymptPain_AfterUpdate()
- If IntSymptPain.Value = True Then
- Me.IntSymptPain.Picture = Me.ToggleBlue.Picture
- End If
- End Sub
I'm having 2 problems with my shoddy workaround:
1. I'm getting an error:
"Run-time error '2220': Microsoft Access can't open the file 'BtnBlue.bmp'."
When I click debug, the line containing "Me.IntSymptPain.Picture = Me.ToggleBlue.Picture" is highlighted.
2. This only runs on the AfterUpdate event, so when I open a form to this specific record, it doesn't try to get BtnBlue.bmp until after the button has been clicked. I know I could add the code to multiple events within the form, but seeing as I have multiple toggle buttons, wouldn't that get a little ridiculous?