Forum: IronRuby Re: how to initialize iron ruby from c#

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
48d1aca7191f2d16e184971054c7c143?d=identicon&s=25 Meinrad Recheis (Guest)
on 2009-02-08 11:29
(Received via mailing list)
> Date: Sun, 8 Feb 2009 01:20:48 +0100
>
From: Thibaut Barr?re <thibaut.barrere@gmail.com>
>
Subject: Re: [Ironruby-core] how to initialize iron ruby from c#
>
To: ironruby-core@rubyforge.org
>
Message-ID:
>
       <4a68b8cf0902071620s6ab94899y167f0d8006c781d9@mail.gmail.com>
>
Content-Type: text/plain; charset="iso-8859-1"
>

> the task because there seem to have been much changes in iron ruby lately.
>
>
>

> not sure if it will solve your issue, but here's what I'm using (worked a
>
few days ago - code snippet sent by Tomas Matousek):
>

> var engine = IronRuby.Ruby.CreateEngine();
>
engine.Execute(code);
>

> hth,
>

> -- Thibaut


Thanks Thibaut, I tried that, and get the same error. Maybe I should try
out
older binaries.

Apart from that, I want to make sure, that my approach to embedding
IronRuby
in a .NET app is right (didn't find any tutorials on embedding):

1) Add references to IronRuby.dll, IronRuby.Libraries.dll,
Microsoft.Scripting.dll and Microsoft.Scripting.Core.dll
2) Create a engine like this

var engine = IronRuby.Ruby.CreateEngine();

and then executie ruby code on the engine itself with Execute, or
compile
code into a ScriptSource and execute that.
Are there any steps missing? ir.exe has a config file. I don't need one
to
get iron ruby basically running, do I?
The standard library is embedded in IronRuby.Libraries.dll, so I don't
need
to set a load path, right?

I would be willing to write a tutorial on embedding once I got
everything
together and working.

Thanks for clarification,
-- henon
This topic is locked and can not be replied to.