Even if you could pass this to the eval function, and there are ways to do it, like eval.call(this,$bp), native eval seems to have no respect for this. It doesn't inject this into the compilation of the string. I fed this to the duktape shell and to the mozilla js shell. You would expect to get 3 and 3, but we get 3 and then undefined. t = {x:3, eval:eval, a:function(){print(this.x)}}; t.a(); t.eval("this.x"); Unless there is some other clever workaround, you'd have to say window.z=this,eval($bp) and refer to z as needed, assuming z was not already a local variable, and remembering to delete z when done (cleaning up), or var z = this; eval($bp); if the point of injection allows that syntax. This is getting kinda awkward but it's all I have. Karl Dahlke