6

Is it possible to expose an API in a .NET application by embedding a scripting language like IronPython?

How is it done?

Huppie
  • 11,263
  • 4
  • 32
  • 34
guillermooo
  • 7,915
  • 15
  • 55
  • 58

2 Answers2

6

IronPython has a hosting API which can be used to execute IronPython scripts from a C#\VB application.

This is a good example of embedding IronPython inside a winforms app.Note that the hosting APIs have changed since that post. This post shows an example of the latest API

You can find the latest specs here [Note: URL throws a 404 as of 2010-09-07]

tzot
  • 92,761
  • 29
  • 141
  • 204
  • Thanks! It would be great if you could also indicate some advantages/disadvantages of using Iron* over VSTA (apart from tech support). – guillermooo Oct 16 '08 at 23:32
1

I haven't used it personally, but you should look at Visual Studio Tools for Applications

I'm not sure if Iron Python is supported as a language for it or not, but that would be the easiest path to enable your application to be programmable.

Michael Brown
  • 9,041
  • 1
  • 28
  • 37