The Joel on Software Discussion Group (CLOSED)

A place to discuss Joel on Software. Now closed.

This community works best when people use their real names. Please register for a free account.

Other Groups:
Joel on Software
Business of Software
Design of Software (CLOSED)
.NET Questions (CLOSED)
TechInterview.org
CityDesk
FogBugz
Fog Creek Copilot


The Old Forum


Your hosts:
Albert D. Kallal
Li-Fan Chen
Stephen Jones

Making a .NET application scriptable?

My current project is a .NET Windows Forms application for financials traders.  We need to allow users to write scripts to control the application, for example, placing orders. 

What are the alternatives for this?  Visual Studio for Applications (VSA) seems to be the right technology choice, but http://msdn.microsoft.com/msdnmag/issues/02/08/VisualStudioforApplications/ is the only decent article we've found on this subject, and there are disturbing rumors in the groups that VSA is dead in .NET 2.0 ( http://groups.google.com/groups?hl=en&lr=&selm=upHG%23uPoEHA.3324%40TK2MSFTNGP10.phx.gbl ).

I haven't been able to find much on MSDN, I keep coming back to the Windows Script page ( http://msdn.microsoft.com/scripting/ ) which is light on information and hasn't been updated recently.

Thoughts?
Hockey Player Send private email
Thursday, October 28, 2004
 
 
Use the Windows Scripting Control.  It let's you execute VB and Java script within your program.

Thursday, October 28, 2004
 
 

Thursday, October 28, 2004
 
 
Well. There's a lot of support in .NET for dynamically compiling things - could one option be providing the ability for users to write macro functions in VB.NET or C# and then compiling those into classes which you can use via reflection?
John Christensen Send private email
Thursday, October 28, 2004
 
 
This would be bleeding edge stuff, but you can check out IronPython

http://www.ironpython.com/

long term is sounds as if Python will become a .NET first class citizen, but it is certainly not there yet.
Bart Park
Thursday, October 28, 2004
 
 
This depends on what is the level of complexity of the scripts and how integrated with your code you want your solution.

For simple scripts and not too integrated, I would go with the Microsoft Script Control. I've used it without a form and works fairly well.

For more complex stuff, I just compile .NET code on the fly. There is no easy way to unload/reload scripts at the moment in .NET. The easiest hack I've seen is to load your scripts in a different AppDomain.

This article got me started:

http://www.divil.co.uk/net/articles/plugins/scripting.asp

I have a server app (albeit in apha form at the moment) that does some functionality from source code. Click on my name to get there.
Slartibartfast Send private email
Thursday, October 28, 2004
 
 
maybe look at the newsgroup
microsoft.public.dotnet.scripting
rain rain go away
Friday, October 29, 2004
 
 

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics
 
Powered by FogBugz