How to set parameter value is type image

Stimulsoft Ultimate discussion
Post Reply
pdt1704
Posts: 60
Joined: Tue Nov 15, 2011 9:12 pm

How to set parameter value is type image

Post by pdt1704 »

Hi all,
I have parameter variable has type is image, how can I set byte array to this parameter.
Please help.

Best Regards,
Thanh
HighAley
Posts: 8430
Joined: Wed Jun 08, 2011 7:40 am
Location: Stimulsoft Office

Re: How to set parameter value is type image

Post by HighAley »

Hello, Thanh.

You could use next code to load the image from byte array:

Code: Select all

report.Dictionary.Variables["Image"].ValueObject = Image.FromStream(new MemoryStream(bytes));
Thank you.
pdt1704
Posts: 60
Joined: Tue Nov 15, 2011 9:12 pm

Re: How to set parameter value is type image

Post by pdt1704 »

Hi HighAley,
It run OK now.
Thank you.

Best Regards,
Thanh
HighAley
Posts: 8430
Joined: Wed Jun 08, 2011 7:40 am
Location: Stimulsoft Office

Re: How to set parameter value is type image

Post by HighAley »

Hello, Thanh.

We are always glad to help you.
Let us know if you need our help.

Thank you.
Post Reply