Re: [IronPython] _scriptEngine.Shutdown ( )

2008-08-24 Thread Huzaifa
right but it is not available in the latest code for ipy 2.0. Curt Hagenlocher wrote: > > I'm afraid I don't quite see the question in there :). > > The purpose of ScriptEngine.Shutdown is to support functionality like > Python's sys.exitfunc. > > On S

[IronPython] _scriptEngine.Shutdown ( )

2008-08-23 Thread Huzaifa
scriptEngine.Shutdown ( ) Is this method replaced ,if yes then with without. -- View this message in context: http://www.nabble.com/_scriptEngine.Shutdown-%28-%29-tp19127524p19127524.html Sent from the IronPython mailing list archive at Nabble.com. ___

Re: [IronPython] CodeContext

2008-08-23 Thread Huzaifa
instance via engine.GetService(). > > Tomas > > -Original Message- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] On Behalf Of Huzaifa > Sent: Saturday, August 23, 2008 4:56 PM > To: users@lists.ironpython.com > Subject: [IronPython] CodeContext >

[IronPython] CodeContext

2008-08-23 Thread Huzaifa
how to get CodeContext from ScriptRuntime ,ScriptScope or ScriptEngine . basically i am try use this function: public static PythonTuple/*!*/ GetExceptionInfoLocal(CodeContext/*!*/ context, Exception ex) -- View this message in context: http://www.nabble.com/CodeContext-tp19126500p1912650

[IronPython] sandboxing

2008-08-22 Thread Huzaifa
private static PermissionSet ps = new PermissionSet(PermissionState.None); ps.AddPermission(new SecurityPermission(SecurityPermissionFlag.Execution)); ps.AddPermission(new FileIOPermission(FileIOPermissionAccess.PathDiscovery | FileIOPermissionAccess.Read, Path)); public static vo

[IronPython] Re strict imports

2008-08-22 Thread Huzaifa
how can i restrict my user that he can not perform any imports or I/O operations in the script. -- View this message in context: http://www.nabble.com/Restrict-imports-tp19113682p19113682.html Sent from the IronPython mailing list archive at Nabble.com. _

[IronPython] System.Scripting.Runtime.UnboundNameException

2008-08-10 Thread Huzaifa
pe ( ); ScriptEngine curEngine = env.GetEngine ("py"); ScriptSource input; env.LoadAssembly (typeof (System.Diagnostics.Debug).Assembly); env.Globals.SetVariable("name","Huzaifa"); input = curEngine.CreateScriptSourceFromString ( @"

Re: [IronPython] IAttributesInjector

2008-08-08 Thread Huzaifa
; > [SpecialName] > public static void SetMember(string self, string name, object > value) { >Console.WriteLine("Set called, {0}, {1}", name, value); > } > } > > -Original Message- > From: [EMAIL PROTECTED] > [mail

[IronPython] IronPython.Runtime.Exceptions.ImportException: No module named System

2008-08-05 Thread Huzaifa
I am trying this code , and it is giving me this exception "IronPython.Runtime.Exceptions.ImportException: No module named System" input = _scriptEngine.CreateScriptSourceFromString ( @"import clr from System import * clr.AddReferenceToFile("ABC.dll') ", System.Scripting.SourceCodeKind.Statement

[IronPython] how to convert this code in py 2.0

2008-07-30 Thread Huzaifa
Ops.ExtractException (ex, _pythonengine.Sys); TraceBack tb = _pythonengine.Sys.exc_traceback as TraceBack; if (tb != null) { ex.Data["LineNumber"] = tb.Line; //How to get Column? ex.Data["Offset"] = tb.Offset; //doesn't work? I am not able to convert

[IronPython] pyEngine.Execute

2008-07-30 Thread Huzaifa
pyEngine.Execute(script); What is the equivalent of this code in ironpython 2 . -- View this message in context: http://www.nabble.com/pyEngine.Execute-tp18748152p18748152.html Sent from the IronPython mailing list archive at Nabble.com. ___ Users ma

[IronPython] PythonEngine

2008-07-29 Thread Huzaifa
I am not able to run this code with ironpython 2.0 PythonEngine _pyEngine; pyEngine = new PythonEngine(); _pyEngine.Globals["x"] = _x; -- View this message in context: http://www.nabble.com/PythonEngine-tp18720203p18720203.html Sent from the IronPython mailing list archive at Nabble.com. _

[IronPython] difference b/w ironpython 1 and 2.

2008-07-29 Thread Huzaifa
Suggest me a book or link to find changes b/w ironpython 1 and 2. -- View this message in context: http://www.nabble.com/difference-b-w-ironpython-1-and-2.-tp18718624p18718624.html Sent from the IronPython mailing list archive at Nabble.com. ___ Users

Re: [IronPython] IAttributesInjector

2008-07-29 Thread Huzaifa
imples in IronPythonTest project. > > > Follow my heart > Colin Han @ GrapeCity > > -Original Message- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] On Behalf Of Huzaifa > Sent: 2008年7月29日 15:26 > To: users@lists.ironpython.com > Subject: [IronPyt

[IronPython] IAttributesInjector

2008-07-29 Thread Huzaifa
I can not find this interface in ironpython 2.0 .What is the alternative if this interface have been removed. -- View this message in context: http://www.nabble.com/IAttributesInjector-tp18701101p18701101.html Sent from the IronPython mailing list archive at Nabble.com.

[IronPython] Ironpython exception

2008-06-12 Thread Huzaifa Gain
I am embedding Ironpython code into C# code and my C# code is using a COM component which i am using into Python code. Please suggest me what would be the best approach to handle exceptions. Showing Line # and column # in exception message for the embedded python code is a must. -- View this me

[IronPython] Python Exception

2008-06-12 Thread Huzaifa Gain
I am embedding Ironpython code into C# code and my C# code is using a COM component which i am using into Python code. Please suggest me what would be the best approach to handle exceptions. Showing Line # and column # in exception message for the embedded python code is a must. __