Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
THRUST SERVICES & TOOLS
CLOUD EDITIONS
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Intelligence (Analytics)
Dataset values in a masterpage header
doublehawk
Hi,
I have a table with worksets and a parameter to choose one of these worksets.
So I get one row with informations like oid, releasename, comment etc.
These informations I need in the masterpage header. But in the masterpage editor I cant drop tabledata into my header but parameters,varibles and autotext.
Maybe I can get the informations into a variable with a javascript expression? Where can I get some further informations about the "native javascript functions" and "birt functions" in the expression builder?
Someone has an idea?
Find more posts tagged with
Comments
JasonW
Take a look at the attached example. It uses a beforeFactory script to swap datasets. It then uses a table with oncreate and onpagebreak scripts to set a pageVariable to be displayed in the header on the master page.
Jason
doublehawk
Hey Jason,
thanks for your fast response.
Swapping the datasets works but displaying the pageVariable in your attached example doesnt work in my opinion. All I see is the blue background but not an ordernumber how it was intended for I guess.
Another issue for me is to get these values directly from the dataset without creating a table. Is this also possible? For example in the onFetch event of the dataset?
JasonW
If you are just doing a preview it will be empty. You have to use the View Report in Web Viewer toolbar action. This is because page variables only work when using a run task and then a render task, which the standard preview does not do.
If the dataset is not bound to a report item it will never be called. Additionally the onFetch order may change if you use aggregates in a table so it is not a reliable place to get the values. If you do not want to show the table just set its visibility to false, which executes the dataset but shows no values in the report.
Jason