cancel
Showing results for 
Search instead for 
Did you mean: 

Removing # and ALL values in drop down

Former Member
0 Kudos

Hi,

I have used a drown down box in WAD when I click the drop down box I can see the values like ALL, # ,how can I remopve these values'

Thanks

Priya

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Check OSS note 597042.

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi,

I've included the following javascript code in the web template to get around this. This is mainly for the values in the table. You might need to modify the code slightly to include drop-downs as well.

<!-- script to replace blank data in BW with space -->

<SCRIPT>

window.onload=Init

function Init()

{

var Elements=document.getElementsByTagName('TD');

for(var i=0;i<Elements.length;i++)

{

var str=Elements<i>.innerText;

var found=str.search(/Not assigned/)

if ((found >=0 || str=='#') && str.length<50)

{

Elements<i>.innerHTML ='&nbsp;'

}

}

Elements=null

}

</SCRIPT>

Former Member
0 Kudos

Hi Lashan,

Thanks for your reply

Pls let me know how to avoid value= ALL in my drop down as I am unablr to understanf the below code

Former Member
0 Kudos

Hi... Not really a javascript expert, but I've changed a few lines in the code below. Pls check if it works for you as I haven't really tested it with the changes.

Notes:

Line 5: this line is used to get the values contained within the html tags. I am assuming the html tag for the drop down which contains these values is 'OPTION'. if not change to the appropriate tag.

Line 10: Added str=='ALL' to the if condition. I've also used str.length<50 so I don't select cells with large values. you can remove this if it is not applicable to you.

<SCRIPT>

window.onload=Init

function Init()

{

var Elements=document.getElementsByTagName('OPTION');

for(var i=0;i<Elements.length;i++)

{

var str=Elements.innerText;

var found=str.search(/Not assigned/)

if ((found >=0 || str=='#' || str=='ALL') && str.length<50)

{

Elements.innerHTML =' '

}

}

Elements=null

}

</SCRIPT>