pass a js variable from one function to another

How cn I pass a variable from one js function to another without declaring it global?

I need to pass a variable created in a function to:

function loadXMLDoc()
Who is Participating?
If you are calling that function from the other function then just pass it

function somefunction(){

function loadXMLDoc(myvar) {

Open in new window

robrodpAuthor Commented:
I thought so... thx Gary.

You are the real McCoy
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.