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

radio button How to change vertically to Horizantly

Started by Revathi_M, 29 Oct 2014 07:02:29 AM

Previous topic - Next topic

Revathi_M

Any body export help me

radio button How to change vertically to Horizantly

BigChris


Revathi_M

Hi bigchris,

when i run report the radiobutton output like display:
.A
.B
.C

but i want when run the report Display like .A .B .C

cognos810

Hello Revathi_M,
There is no stright forward out-of-the-box way of doing this. But, can be done using Javascript/HTML items.

-Cognos810

cognos810

Here you go:

Simply add two HTML items on the left and right of your radio button.
On the left of the radio button prompt, HTML item should have: <div id="radioDiv">
and on the right side the HTML item should have </div>

Then create another HTML item and paste the below code in it.

<script type="text/javascript">   
function inlineRadios(child)
{

if((child.type == "radio")||(child.type == "checkbox"))
{
child.parentNode.parentNode.style.display="inline";
child.parentNode.parentNode.style.whiteSpace="noWrap";
}
}   

function promptDescendants (node)
{

for (var i = 0; i < node.childNodes.length; i++)
{
var child = node.childNodes;
inlineRadios(child);
promptDescendants(child);
}
}
var theDiv = document.getElementById("radioDiv");
promptDescendants(theDiv);
</script>