Dino Viehland wrote:
We're picking the ObjectHandle overload for some reason. You can use .Overloads to select the correct overload. I'm actually surprised you don't get a different type error saying the call is ambiguous so I'll have to take a deeper look to understand that.
Actually, this rings a bell. I think I might have asked this question before and received the same answer...
Thanks for the quick reply! Michael
-----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Michael Foord Sent: Thursday, October 30, 2008 9:02 AM To: Discussion of IronPython Subject: [IronPython] ScriptScope Oddity Why does setting '__file__' to None on a ScriptScope through 'SetVariable' fail, whilst setting it directly as an attribute (from inside IronPython) succeeds? Is this intentional? >>> scope <Microsoft.Scripting.Hosting.ScriptScope object at 0x0000000000000034 [Microsoft .Scripting.Hosting.ScriptScope]> >>> scope.SetVariable('__file__', None) Traceback (most recent call last): File "<stdin>", line 1, in <module> TypeError: Value cannot be null. Parameter name: handle >>> scope.__file__ = None >>> Michael -- http://www.ironpythoninaction.com/ _______________________________________________ Users mailing list [email protected] http://lists.ironpython.com/listinfo.cgi/users-ironpython.com _______________________________________________ Users mailing list [email protected] http://lists.ironpython.com/listinfo.cgi/users-ironpython.com
-- http://www.ironpythoninaction.com/ _______________________________________________ Users mailing list [email protected] http://lists.ironpython.com/listinfo.cgi/users-ironpython.com
