displaying image within code

Stimulsoft Reports.PHP discussion
Post Reply
stvhui
Posts: 51
Joined: Wed Apr 22, 2009 3:12 am

displaying image within code

Post by stvhui »

Hello to you,
I'm using stimulsoft report fx php 2016.3

I've employee table contains (empolyee no, name, gender, etc)
I've images stored in d:\male.jpg and d:\female.jpg

I want to create a report of employee, when gender is "male" then displaying image in d:\male.jpg and..
when gender is "female" then displaying image in d:\female.jpg

How to write above code into report.
Please guide & showing me by code.

Thanks & Regards,
Steven
Alex K.
Posts: 6488
Joined: Thu Jul 29, 2010 2:37 am

Re: displaying image within code

Post by Alex K. »

Hello,

Please try to add two Image components and Condition with "ComponentIsEnabled" option and show only necessary.

Thank you.
stvhui
Posts: 51
Joined: Wed Apr 22, 2009 3:12 am

Re: displaying image within code

Post by stvhui »

How to writing its code

Please show me, I 'd searching the documentation, but no documented.

I means, just put the code as image.loadfrom("d:/male.jpg") or how?
Alex K.
Posts: 6488
Joined: Thu Jul 29, 2010 2:37 am

Re: displaying image within code

Post by Alex K. »

Hello,

Please check the sample report in the attachment.

Thank you.
Attachments
ReportCondition.mrt
(4 KiB) Downloaded 355 times
stvhui
Posts: 51
Joined: Wed Apr 22, 2009 3:12 am

Re: displaying image within code

Post by stvhui »

Hello to you,
Thanks for your example, but not solved my problems because yr sample is embeded the image's file into report's file.

My problems is I don't know how to display/showing images into report (the images is stored into d:\male.jpg)
I want to call/load images file that stored into d:\male.jpg

Please give me an example, thanks in advance.
Alex K.
Posts: 6488
Joined: Thu Jul 29, 2010 2:37 am

Re: displaying image within code

Post by Alex K. »

Hello,

Please try to set the Image - File property.

Thank you.
Post Reply