[IronPython] IP 2.7b1 - Accessing C# variables from Python

Ron Lindsey ron at emirot.com
Wed Jan 5 20:25:20 CET 2011


Thanks for the reply. To your question, No. The real problem here is how 
do i get access to the variables in c# from ironpython.

Thanks, Ron Lindsey

On 1/5/2011 1:22 PM, Daniel Jennings wrote:
> Have you tried just treating it like a regular Python dictionary? I thought that's all I had to do, though I work with Dictionary<K,V>, not Hashtable objects.
> -----Original Message-----
> From: users-bounces at lists.ironpython.com [mailto:users-bounces at lists.ironpython.com] On Behalf Of Ron Lindsey
> Sent: Wednesday, January 05, 2011 11:21 AM
> To: users at lists.ironpython.com
> Subject: [IronPython] IP 2.7b1 - Accessing C# variables from Python
> I have written an OpenGL 3D modeling program in C#/OpenTK. In the
> program, I store all the objects (box, sphere, tube, etc) the user
> created into a hashtable. Each object stored is of type Box, Sphere etc...
> I am embedding IronPython to give the user a way to animate their
> models. So in IronPython, the user needs to have access to the objects
> in the hashtable to get/set properties of the different objects.
> Once the script is written, they then will run it. as the script
> executes, it will control the objects in the hashtable, which in turn
> will move the 3D models in the screen.
> I have looked/googled/read but have not found out a way to access a C#
> hashtable and the objects stored with in it.
> Any ideas?

More information about the Ironpython-users mailing list