If you are unable to create a new account, please email support@bspsoftware.com

 

News:

MetaManager - Administrative Tools for IBM Cognos
Pricing starting at $2,100
Download Now    Learn More

Main Menu

How do I hide a drillthrough link and retain functionality??

Started by garydobson87, 17 Apr 2015 06:08:50 AM

Previous topic - Next topic

garydobson87

Hi all,

I have a requirement to have a context driven drillthrough to another report. I need the link to be hidden as the user will get the impression he is clicking on a background image to drill through to a report. The image will be the same on every row of a list but the drillthrough takes you to a chart relating to the context of that row. so buttons and static drillthroughs wont serve my purpose.

I've tried various, CSS and Javascript techniques but have been unsuccessful so far.

Basically, I want a dynamic drillthrough that can be hidden but works when clicked on! :)

Changing the font colour to white is also out as the link will sit on top of a background image.


Hoping you guys and gals out there can help!! :(

Thanks so much.

MFGF

Hi,

What about including HTML items (within the list column) to create an Anchor tag around the image? You could base these on a report expression that constructs the URL of the target report and adds &p_YourParameter=xxxxx to pass a data item value in the URL to the target report.

Worth a shot?

MF.
Meep!


MFGF

Quote from: garydobson87 on 17 Apr 2015 08:42:56 AM
;D

Thanks MF..

You're clearly more adept than myself at this..

Could you help me further please?  I simply have no idea what to put where!

The data items I need to pass [Range] and [Exclusive Brand]
the parameters I need to pass are..

p_Branch
p_dateFrom
p_dateTo





The URL is:

http://10.112.197.10/ibmcognos/cgi-bin/cognosisapi.dll?b_action=cognosViewer&ui.action=run&ui.object=%2fcontent%2ffolder%5b%40name%3d%27Administration%27%5d%2ffolder%5b%40name%3d%27Reports%27%5d%2ffolder%5b%40name%3d%271.DEV%27%5d%2ffolder%5b%40name%3d%27Product%20Reporting%27%5d%2ffolder%5b%40name%3d%27PRD_005%20-%20Exclusive%20Brands%20%26%20Associated%20Reports%27%5d%2freport%5b%40name%3d%27PRD_005%20(b)%20Chart%20Drillthrough%27%5d&ui.name=PRD_005%20(b)%20Chart%20Drillthrough&run.outputFormat=&run.prompt=true&ui.backURL=%2fibmcognos%2fcgi-bin%2fcognosisapi.dll%3fb_action%3dxts.run%26m%3dportal%2fcc.xts%26m_folder%3diA688C10074B5465D8FF3ECE76FCC5216



Obviously i don't expect you to do it for me, just point me in the right direction please.

Thanks!!!

Ha! Adept is not a word I would normally associate with a muppet such as myself :)

So, the approach is:

1. Unlock the structure of your report. Drag HTML items from the toolbox into the list column containing the image - one before and one after the image object.
2. For the second HTML item, leave the Source Type as Text, and set the HTML to be a closing anchor tag < /a >
3. For the first HTML item, set the Source Type to be Report Expression, and set the Report Expression to be the opening anchor tag, with syntax like:

'<a href=http://10.112.197.10/ibmcognos/cgi-bin/cognosisapi.dll?b_action=cognosViewer&ui.action=run&ui.object=%2fcontent%2ffolder%5b%40name%3d%27Administration%27%5d%2ffolder%5b%40name%3d%27Reports%27%5d%2ffolder%5b%40name%3d%271.DEV%27%5d%2ffolder%5b%40name%3d%27Product%20Reporting%27%5d%2ffolder%5b%40name%3d%27PRD_005%20-%20Exclusive%20Brands%20%26%20Associated%20Reports%27%5d%2freport%5b%40name%3d%27PRD_005%20(b)%20Chart%20Drillthrough%27%5d&ui.name=PRD_005%20(b)%20Chart%20Drillthrough&run.outputFormat=&run.prompt=false&p_p_Branch='; + [your Branch value query item] + '&p_p_dateFrom=' + [your from date query item] + '&p_p_dateTo=' + [your to date query item] + '&ui.backURL=%2fibmcognos%2fcgi-bin%2fcognosisapi.dll%3fb_action%3dxts.run%26m%3dportal%2fcc.xts%26m_folder%3diA688C10074B5465D8FF3ECE76FCC5216>'

Here we are passing values via the URL to fulfill the prompt parameters on the target report. Each parameter is sent in the form p_YourParameterName=Value. We are taking the values from data items in the query of your source report.

Hope that helps!!

MF.
Meep!

garydobson87

Amazing!!

Thank you so much,

Almost there.. Doesnt seem to like the branch or date fields though.. Variable invalid?

Ive attached the XML if you'd mind taking a look?

Thanks again!



MFGF

Quote from: garydobson87 on 17 Apr 2015 11:12:16 AM
Amazing!!

Thank you so much,

Almost there.. Doesnt seem to like the branch or date fields though.. Variable invalid?

Ive attached the XML if you'd mind taking a look?

Thanks again!

Hi,

It looks like you're referencing items from Query6 in your expression? At the moment you just have [Branch], but if you drag in this item from Query6 into your expression, it gets represented as [Query6].[Branch]

Try dragging in the items from the list of items in your query rather than (I assume) hand-coding the item in the expression :)

Cheers!

MF.
Meep!

barrysaab

Boy! Cognos getting on to me!!!

garydobson87

Hi again!

Thanks so much for your help so far MF, you've really steered me in the right direction!!.

After a lot of tinkering and testing I had gotten the syntax in my URL working for all but one element..

Dynamically passing multiselect values from one report to another via URL.

Ive seen similar threads where you contributed but a solid solution didnt seem to present itself.

My logic so far:

'<a href="http://10.112.197.10/ibmcognos/cgi-bin/cognosisapi.dll?b_action=cognosViewer&ui.action=run&ui.object=%2fcontent%2ffolder%5b%40name%3d%27Administration%27%5d%2ffolder%5b%40name%3d%27Reports%27%5d%2ffolder%5b%40name%3d%271.DEV%27%5d%2ffolder%5b%40name%3d%27Product%20Reporting%27%5d%2ffolder%5b%40name%3d%27PRD_005%20-%20Exclusive%20Brands%20%26%20Associated%20Reports%27%5d%2freport%5b%40name%3d%27PRD_005%20(b)%20Chart%20Drillthrough%27%5d&ui.name=PRD_005%20(b)%20Chart%20Drillthrough&run.outputFormat=&run.prompt=false&p_dateFrom='+ParamDisplayValue('dateFrom')+'&p_dateTo='+ParamDisplayValue('dateTo')+'&p_Branch='+ParamDisplayValue('Branch')+'&p_Range='+[RangeName]+'&p_ExclusiveBrand='+[ExclusiveBrand]+'" target="_blank">'

The Branch parameter is the multi select prompt value that needs to be passed, the above code returns the first branch selected.

Thie below code returns multiple branches, but it returns ALL the branches you specify in the selectChoices section, not just the ones selected at prompt.

'<a href="http://10.112.197.10/ibmcognos/cgi-bin/cognosisapi.dll?b_action=cognosViewer&ui.action=run&ui.object=%2fcontent%2ffolder%5b%40name%3d%27Administration%27%5d%2ffolder%5b%40name%3d%27Reports%27%5d%2ffolder%5b%40name%3d%271.DEV%27%5d%2ffolder%5b%40name%3d%27Product%20Reporting%27%5d%2ffolder%5b%40name%3d%27PRD_005%20-%20Exclusive%20Brands%20%26%20Associated%20Reports%27%5d%2freport%5b%40name%3d%27PRD_005%20(b)%20Chart%20Drillthrough%27%5d&ui.name=PRD_005%20(b)%20Chart%20Drillthrough&run.outputFormat=&run.prompt=false&p_dateFrom='+ParamDisplayValue('dateFrom')+'&p_dateTo='+ParamDisplayValue('dateTo')+'&p_Range='+[RangeName]+'&p_ExclusiveBrand='+[ExclusiveBrand]+'&p_Branch=<selectChoices>
<selectOption useValue=%22Head Office%22 displayValue=%22Head Office%22/>
<selectOption useValue=%22Head Office International%22 displayValue=%22Head Office International%22/>
<selectOption useValue=%22Head Office W3%22 displayValue=%22Head Office W3%22/>
<selectOption useValue=%22Head Office Wa%22 displayValue=%22Head Office Wa%22/>
<selectOption useValue=%22Head Office Wb%22 displayValue=%22Head Office Wb%22/>
<selectOption useValue=%22Head Office Wc%22 displayValue=%22Head Office Wc%22/>
</selectChoices>" target="_blank">'




Pulling my hair out over here guys... Any help would be awesome!!! :(

Thanks in advance.