i am sorry i had to remove double quotes too :
Yes you do. If you leave the double quotes, you are NOT assigning a function reference. You are assigning a string. In the future, instead of replying with a condescending response ("please try before posting a solution") do make an effort to read what what ACTUALLY suggested. Clearly I did NOT suggest those quotes.
But, how will you pass a parameter to that function if it requires any?
In that case you use an anonymous function and call your function from within the anonymous function: btn.onclick = function(){doSomething("This is the param you are passing");};