can’t get value from onclick function javascript

I have a function where I am trying to get a value from an onclick event.

Here is the element attribute that gives the function to the element:

listcontainer.setAttribute('onmousedown',"knowbe4campaignspecific(this)")

Here is the function code:

function knowbe4campaignspecific(ele){
    console.log(ele.value)}

However it will say undefined in the developer console.

If I just print the element by itself it will show the value inside so I must be missing something basic.

function knowbe4campaignspecific(ele){
    console.log(ele)}

##RESULTS##
<ul value="183085" onmousedown="knowbe4campaignspecific(this)" class="ms-List"></ul>

Let me know if anything else is needed and I will update this post. Thanks!