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

 

Cognos 8.4.1 JavaScript question: Default selection for a checkbox prompt list

Started by dtopicMedV, 11 Jan 2011 02:12:43 PM

Previous topic - Next topic

MFGF

Quote from: mohsin2010 on 25 Jan 2011 10:41:29 PM
HI  Muppet  :),

  how are you i m not using Cognoise now days due to my Examinations i will right back soon Take Care ;D 

Bst Regards,
Mohsin
       

Hope the exams go well. Good luck!
Meep!


Suraj

Funny... :o
I was searching for a Cognos 10 JS to select 1st value in a value prompt and had high hopes when I clicked on this thread. The C8 version doesn't work anymore.
I guess at least I got some healthy tips. ;)

melee

Quote from: Suraj Neupane on 02 Feb 2011 06:02:23 PM
Funny... :o
I was searching for a Cognos 10 JS to select 1st value in a value prompt and had high hopes when I clicked on this thread. The C8 version doesn't work anymore.
I guess at least I got some healthy tips. ;)

Oy! Did they change the prompt ID scheme?

cognostechie

Quote from: Suraj Neupane on 02 Feb 2011 06:02:23 PM
Funny... :o
I was searching for a Cognos 10 JS to select 1st value in a value prompt and had high hopes when I clicked on this thread. The C8 version doesn't work anymore.
I guess at least I got some healthy tips. ;)

What did you mean? I just upgraded mt recent report from 8.4 to 10 and worked fine !!

Suraj

Quote from: cognostechie on 02 Feb 2011 08:20:59 PM
What did you mean? I just upgraded mt recent report from 8.4 to 10 and worked fine !!
What javascript did you use in C8 for this that worked in C10?
thanks for sharing



kado

Anybody got something clean and simple like this to work in Cognos 10.

1) I set the Name of the Value Prompt, list box to 'SF' (which only has 1 value to pick but different for every user)
2) then drop an HTML after the Value Prompt and paste in this code:

<script language="javascript">
var f = getFormWarpRequest();
var list = f._oLstChoicesSF;
list[2].selected=true
</script>

Nothing happens :( ... what I'm jones'n for is to have this one value (which is different for every user) selected (highlighted in blue) and auto-submitted.

Any thoughts out there?

THANKS!