From: Ralph Mason Date: 2001-11-18T12:56:50+09:00 Subject: [ruby-talk:25738] Re: WIN32OLE I plan on releasing the source. However it only compiles on VC++ and is unlike the other extensions that are out there. I guess it's not really and 'extension' since it loads ruby etc. It is working, and I plan on releasing it in the next week or so to get feedback. There are some paradigms that are harder to make fit together between ruby and the idispacth, especially when it comes to iterators, the main problem being that ruby iterators call a code block where a IEnum type iterator the codeblock calls the iterator, which makes a efficient implementation almost impossible. I don't really know the implications of putting something in the RAA but am happy to do that if it makes it useful. If anyone wants to help with testing and suggestions that would be cool. Here is a little example of where is at (run in the VB immediate window) Set x = CreateObject("Ruby.Myclass") Set y = CreateObject("Ruby.Myclass") ? x # ? y # x.set_x("Testing") ? x # y.set_x y ?y #> ?x.type Myclass ?x.type = y.type True ? x.Str Test And The ruby code class Myclass def test 123 end def test1(x) x end def test2(x,y) [x,y] end def Str "Test" end def set_x(y) @x = y end def x @x end end For me it's pretty exciting, you can pretty pass ruby or com objects across the interface at will and and call functions from either side. So you could design an interface in VB and then pass all the interface objects to the ruby backend. This would also mean you endup with an 'executable' making it easier to ship onto windows platforms. Ralph ----- Original Message ----- From: "MikkelFJ" Newsgroups: comp.lang.ruby To: "ruby-talk ML" ; Sent: Sunday, November 18, 2001 2:28 PM Subject: [ruby-talk:25736] Re: WIN32OLE > "Ralph Mason" wrote in message > news:037901c16ee8$d3e039c0$0101a8c0@p3... > > I am working on Win32 Ole support in ruby. The main thrush is to allow > ruby > > to be at both sides of the equation. I have been using some bits of the > > current Win32 Ole module but am rewriting many bits > > > > I have it mostly working now so you can create Ruby object via IDisaptch > > > > e.g. > > > > Set MyObject = CreateObject("Ruby.MyClass") > > This is great news. > What is the availability of your source? > Are you planning a release to RAA? > > MikkelFJ > > > >