Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
PUBLIC CLOUD
PRIVATE CLOUD
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Intelligence (Analytics)
Image in MasterPage that changes with Parameter
kidtorres
Hi all, I am new in the forum, and new on Birt, so I hope that someone can help me.
What I am trying to do is to put a Dynamic Image in the Master Page that changes by differents values that can take a parameter.
The dataset is very simple, it has two columns, one is c_empresa (that is the number of an enterprise) and the other column is URL_IMAGE (that has the URL of the image).
The dataset is:
SELECT c_empresa, URL_IMAGE
FROM table
WHERE c_empresa = :c_empresa
What i want to do is that the URI image take the value of the URL_IMAGE column dinamically and not to put the URL hardcoded.
I create a onRender event on the image with this:
this.setURL(row["URL_IMAGE"];
but it doesnt work..
Is it clear??
Sorry for my english.
Thank you in advance.
Find more posts tagged with
Comments
mwilliams
Try this:
this.URI = row["URI_IMAGE"];
kidtorres
<blockquote class='ipsBlockquote' data-author="'mwilliams'" data-cid="117339" data-time="1370410020" data-date="04 June 2013 - 10:27 PM"><p>
Try this:<br />
<br />
this.URI = row["URI_IMAGE"];<br /></p></blockquote>
<br />
Hi Michael, thank you very much for your quick response.<br />
I am not able to do it.. I get this error: there are errors evaluating script.. "row" is not defined...<br />
What i do is the following: I put the image in the masterpage and select the URI option and leave all empty.. go to the image script, and in the onRender I put: this.URI = row["IMAGEN"]; (IMAGEN is the name of the column that has de URL of the image)<br />
Am I doing something wrong?<br />
Thank you very much.<br />
Regards,<br />
Santiago.
mwilliams
Did you remember to bind your image to you dataSet?
kidtorres
<blockquote class='ipsBlockquote' data-author="'mwilliams'" data-cid="117384" data-time="1370497774" data-date="05 June 2013 - 10:49 PM"><p>
Did you remember to bind your image to you dataSet?<br /></p></blockquote>
<br />
It workeddddd!!! jajaj thank you very much Michael.<br />
I binded the imagen to de DataSet and then in the URI of the image I selected the Javascript Sintax option and put row["IMAGEN"] and it workeddd!!,<br />
Thank you veery much, you save me jajaj.<br />
Best Regards..
mwilliams
Great! Glad I could help! Let us know whenever you have questions!