Choose an enbedded image in a ReportViewer Report using an expression

S

slY

Hi!

This is very urgent, I have set of enbedded images in a ReportViewer
Report that I want to visualize using appropriate expressions.


After having uploaded IMG1.jpg IMG2.jpg IMG3.jpg into the ReportViewer
Report, they appear as costants IMG1, IMG2, IMG3

Now, I'd like to set up an image inside the report doing something like


=Switch(Fields!isADog.Value = 1, IMG1, Fields!isACat.Value = 1, IMG2,
Fields!isACow.Value = 1, IMG3)

Is it possible?? I tried, but... mission failed.


Thank you very much,

mc.
 
S

slY

Il 21/01/2010 23.00, slY ha scritto:
=Switch(Fields!isADog.Value = 1, IMG1, Fields!isACat.Value = 1, IMG2,
Fields!isACow.Value = 1, IMG3)

Is it possible?? I tried, but... mission failed.

Hopefully, even if it seems to be not working (the preview is completely
wrong), it works at run-time!
 
Joined
Dec 17, 2010
Messages
1
Reaction score
0
image.value with expression in ReportViewer of VS2005

Once I choose image source as embedded and value using expression.

Switch(Fields!isOwnerSign.Value = 1, davidji, Fields!isOwnerSign.Value = 0, whitesignature)


davidji is an embedded image name.

The VS2005 has compile error: image contains an error [BC30451] name 'davidji' is not declared. So I have to use the following expression with double quotation.

Switch(Fields!isOwnerSign.Value = 1, "davidji", Fields!isOwnerSign.Value = 0, "whitesignature")

Now the image not show (red x)

Can you help me out?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,754
Messages
2,569,527
Members
44,998
Latest member
MarissaEub

Latest Threads

Top