Can you pass variable from within function?

2 basic questions:

  1. Can you pass a ‘var’ from within one function to another?
  2. How do you do it???

Want to pass ‘ObjectID’ which is made up from a result value into the ‘my3d’ function. Doesn’t register it at the moment?

public function cbPages(result:Object):void {
			var objectID:String = result.title;
			trace(objectID);
		}
		
		override protected  function my3d():void {
			cow=new Collada(objectID);
			default_scene.addChild(cow);
		}

Many thanks for your help in advance.