File tree Expand file tree Collapse file tree 1 file changed +9
-2
lines changed Expand file tree Collapse file tree 1 file changed +9
-2
lines changed Original file line number Diff line number Diff line change @@ -67,17 +67,24 @@ void Host_ConsoleCreated(object sender, EventArgs e)
6767
6868 void Console_ConsoleInitialized ( object sender , EventArgs e )
6969 {
70+ string assemblyLocation = System . Reflection . Assembly . GetExecutingAssembly ( ) . Location ;
71+ string assemblyPath = System . IO . Path . GetDirectoryName ( assemblyLocation ) ;
72+
73+
74+ ICollection < string > paths = console . Pad . Console . ScriptScope . Engine . GetSearchPaths ( ) ;
75+ paths . Add ( assemblyPath ) ;
76+ console . Pad . Console . ScriptScope . Engine . SetSearchPaths ( paths ) ;
7077 string startupScipt = "import IronPythonConsole" ;
7178 ScriptSource scriptSource = console . Pad . Console . ScriptScope . Engine . CreateScriptSourceFromString ( startupScipt , SourceCodeKind . Statements ) ;
7279 try
7380 {
7481 scriptSource . Execute ( ) ;
7582 }
7683 catch { }
84+ /*
7785 double[] test = new double[] { 1.2, 4.6 };
7886 console.Pad.Console.ScriptScope.SetVariable("test", test);
79- //_rhinoCore = new Rhino.Runtime.InProcess.RhinoCore(new string[] { "-appmode" }, Rhino.Runtime.InProcess.WindowStyle.Normal, null);
80-
87+ */
8188 }
8289
8390 void MainWindow_Initialized ( object sender , EventArgs e )
You can’t perform that action at this time.
0 commit comments