Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Insert a Picture Conditionally

Status
Not open for further replies.

DaveMac

Technical User
Apr 9, 2000
161
US
Any thoughts on how to insert a picture based on a value? I have a record that is either “Open” or “Closed”. Based on that value in my report I want to display a picture. I know how to get to the picture but what would the code be to show or insert it conditionally. And if we are there what about using strikeout text on the “Closed” work orders.


Thanks,
Dave
 
I am already using something like that:
best choice is to save your pictures as Open.bmp and Closed.bmp in some fixed location, e.g. C:\images.
Then put this in your Form_Current() code:
yourpicturebox.Image="C:\images" & Me.Status & ".bmp"

OK? ;-)
MakeItSo


Andreas Galambos
EDP / Technical Support Specialist
Bowne Global Solutions Wuppertal, Germany
(andreas.galambos@bowneglobal.de)
HP:
 
BTW: "Status" is not a form property, this shall be the name of your control containing the value "Open" or "Closed"
- just to avoid misunderstandings...
[elf]

Andreas Galambos
EDP / Technical Support Specialist
Bowne Global Solutions Wuppertal, Germany
(andreas.galambos@bowneglobal.de)
HP:
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top