Meinrad Recheis
2009-Feb-08 18:54 UTC
[Ironruby-core] cannot initialize Form with IronRuby
IronRuby 1.0.0.0 on .NET 2.0.50727.1433 Copyright (c) Microsoft Corporation. All rights reserved.>>> require "System.Windows.Forms, Version=2.0.0.0, Culture=neutral,PublicKeyTo ken=b77a5c561934e089" => true>>> Form = System::Windows::Forms::Form=> System::Windows::Forms::Form>>> f=Form.new=> #<System::Windows::Forms::Form:0x000005c>>>> f.Show():0: wrong number of arguments (2 for 3) (ArgumentError)>>> f.method( :Show).arity=> 0>>>This is the latest daily DLR build on codeplex from 2009 Feb 1 at 9:36 PM. I read, that with older versions winforms interop has already been working. -- henon -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://rubyforge.org/pipermail/ironruby-core/attachments/20090208/72878b92/attachment.html>
Works on the bits I have. Could you try following? f.method(:Show).clr_members.each { |m| puts m.to_string } It should print Void Show() Void Show(System.Windows.Forms.IWin32Window) Tomas From: ironruby-core-bounces at rubyforge.org [mailto:ironruby-core-bounces at rubyforge.org] On Behalf Of Meinrad Recheis Sent: Sunday, February 08, 2009 10:55 AM To: ironruby-core Subject: [Ironruby-core] cannot initialize Form with IronRuby IronRuby 1.0.0.0 on .NET 2.0.50727.1433 Copyright (c) Microsoft Corporation. All rights reserved.>>> require "System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"=> true>>> Form = System::Windows::Forms::Form=> System::Windows::Forms::Form>>> f=Form.new=> #<System::Windows::Forms::Form:0x000005c>>>> f.Show():0: wrong number of arguments (2 for 3) (ArgumentError)>>> f.method( :Show).arity=> 0>>>This is the latest daily DLR build on codeplex from 2009 Feb 1 at 9:36 PM. I read, that with older versions winforms interop has already been working. -- henon -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://rubyforge.org/pipermail/ironruby-core/attachments/20090208/b28a971d/attachment.html>
Michael Letterle
2009-Feb-08 21:17 UTC
[Ironruby-core] cannot initialize Form with IronRuby
try f.show_dialog On Sun, Feb 8, 2009 at 1:54 PM, Meinrad Recheis <meinrad.recheis at gmail.com>wrote:> IronRuby 1.0.0.0 on .NET 2.0.50727.1433 > Copyright (c) Microsoft Corporation. All rights reserved. > > >>> require "System.Windows.Forms, Version=2.0.0.0, Culture=neutral, > PublicKeyTo > ken=b77a5c561934e089" > => true > >>> Form = System::Windows::Forms::Form > => System::Windows::Forms::Form > >>> f=Form.new > => #<System::Windows::Forms::Form:0x000005c> > >>> f.Show() > :0: wrong number of arguments (2 for 3) (ArgumentError) > > >>> f.method( :Show).arity > => 0 > >>> > > This is the latest daily DLR build on codeplex from 2009 Feb 1 at > 9:36 PM. I read, that with older versions winforms interop has already been > working. > > > -- henon > > > > _______________________________________________ > Ironruby-core mailing list > Ironruby-core at rubyforge.org > http://rubyforge.org/mailman/listinfo/ironruby-core > >-- Michael Letterle IronRuby MVP http://blog.prokrams.com -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://rubyforge.org/pipermail/ironruby-core/attachments/20090208/8be032b8/attachment.html>
Ivan Porto Carrero
2009-Feb-08 21:29 UTC
[Ironruby-core] cannot initialize Form with IronRuby
I just compiled the ironruby version from github with rake and for me the following code works. require "System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" Form = System::Windows::Forms::Form f = Form.new f.show On Sun, Feb 8, 2009 at 7:54 PM, Meinrad Recheis <meinrad.recheis at gmail.com>wrote:> IronRuby 1.0.0.0 on .NET 2.0.50727.1433 > Copyright (c) Microsoft Corporation. All rights reserved. > > >>> require "System.Windows.Forms, Version=2.0.0.0, Culture=neutral, > PublicKeyTo > ken=b77a5c561934e089" > => true > >>> Form = System::Windows::Forms::Form > => System::Windows::Forms::Form > >>> f=Form.new > => #<System::Windows::Forms::Form:0x000005c> > >>> f.Show() > :0: wrong number of arguments (2 for 3) (ArgumentError) > > >>> f.method( :Show).arity > => 0 > >>> > > This is the latest daily DLR build on codeplex from 2009 Feb 1 at > 9:36 PM. I read, that with older versions winforms interop has already been > working. > > > -- henon > > > > _______________________________________________ > Ironruby-core mailing list > Ironruby-core at rubyforge.org > http://rubyforge.org/mailman/listinfo/ironruby-core > >-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://rubyforge.org/pipermail/ironruby-core/attachments/20090208/145697e9/attachment.html>
Meinrad Recheis
2009-Feb-08 23:25 UTC
[Ironruby-core] cannot initialize Form with IronRuby
On yesterdays checkout from git message "syncing to head of tfs" I get: IronRuby 1.0.0.0 on .NET 2.0.50727.1433 Copyright (c) Microsoft Corporation. All rights reserved.>>> require "System.Windows.Forms, Version=2.0.0.0, Culture=neutral,PublicKeyTo ken=b77a5c561934e089" => true>>> System::Windows::Forms::Form.new=> #<System::Windows::Forms::Form:0x000005c>>>> f=System::Windows::Forms::Form.new=> #<System::Windows::Forms::Form:0x000005e>>>> f.Show:0: wrong number of arguments (2 for 3) (ArgumentError)>>> f.show:0: wrong number of arguments (2 for 3) (ArgumentError)>>> f.show_dialog=> #<System::Windows::Forms::DialogResult:0x0000060>>>> f.method(:Show).clr_members.each { |m| puts m.to_string }Void Show(System.Windows.Forms.IWin32Window) => [#<System::Reflection::RuntimeMethodInfo:0x0000062>]>>>On recent git head it works like expected. I will continue testing with the most recent sources. Keep up the great work! Cheers, --henon On Sun, Feb 8, 2009 at 9:58 PM, Tomas Matousek <Tomas.Matousek at microsoft.com> wrote:> Works on the bits I have. Could you try following? > > > > f.method(:Show).clr_members.each { |m| puts m.to_string } > > > > It should print > > > > Void Show() > > Void Show(System.Windows.Forms.IWin32Window) > > > > Tomas > > > > *From:* ironruby-core-bounces at rubyforge.org [mailto: > ironruby-core-bounces at rubyforge.org] *On Behalf Of *Meinrad Recheis > *Sent:* Sunday, February 08, 2009 10:55 AM > *To:* ironruby-core > *Subject:* [Ironruby-core] cannot initialize Form with IronRuby > > > > IronRuby 1.0.0.0 on .NET 2.0.50727.1433 > > Copyright (c) Microsoft Corporation. All rights reserved. > > > > >>> require "System.Windows.Forms, Version=2.0.0.0, Culture=neutral, > PublicKeyToken=b77a5c561934e089" > > => true > > >>> Form = System::Windows::Forms::Form > > => System::Windows::Forms::Form > > >>> f=Form.new > > => #<System::Windows::Forms::Form:0x000005c> > > >>> f.Show() > > :0: wrong number of arguments (2 for 3) (ArgumentError) > > > > >>> f.method( :Show).arity > > => 0 > > >>> > > > > This is the latest daily DLR build on codeplex from 2009 Feb 1 at > 9:36 PM. I read, that with older versions winforms interop has already been > working. > > > > > > -- henon > > > > > > _______________________________________________ > Ironruby-core mailing list > Ironruby-core at rubyforge.org > http://rubyforge.org/mailman/listinfo/ironruby-core > >-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://rubyforge.org/pipermail/ironruby-core/attachments/20090209/bd2060d2/attachment.html>
I fixed this on Friday :) The problem was that Show() declared on Control was hidden by Show(IWin32Window) on Form. It took me a while to make it work :). See http://rubyforge.org/pipermail/ironruby-core/2009-February/003752.html Tomas From: ironruby-core-bounces at rubyforge.org [mailto:ironruby-core-bounces at rubyforge.org] On Behalf Of Meinrad Recheis Sent: Sunday, February 08, 2009 3:26 PM To: ironruby-core at rubyforge.org Subject: Re: [Ironruby-core] cannot initialize Form with IronRuby On yesterdays checkout from git message "syncing to head of tfs" I get: IronRuby 1.0.0.0 on .NET 2.0.50727.1433 Copyright (c) Microsoft Corporation. All rights reserved.>>> require "System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" => true>>> System::Windows::Forms::Form.new=> #<System::Windows::Forms::Form:0x000005c>>>> f=System::Windows::Forms::Form.new=> #<System::Windows::Forms::Form:0x000005e>>>> f.Show:0: wrong number of arguments (2 for 3) (ArgumentError)>>> f.show:0: wrong number of arguments (2 for 3) (ArgumentError)>>> f.show_dialog=> #<System::Windows::Forms::DialogResult:0x0000060>>>> f.method(:Show).clr_members.each { |m| puts m.to_string }Void Show(System.Windows.Forms.IWin32Window) => [#<System::Reflection::RuntimeMethodInfo:0x0000062>]>>>On recent git head it works like expected. I will continue testing with the most recent sources. Keep up the great work! Cheers, --henon On Sun, Feb 8, 2009 at 9:58 PM, Tomas Matousek <Tomas.Matousek at microsoft.com<mailto:Tomas.Matousek at microsoft.com>> wrote: Works on the bits I have. Could you try following? f.method(:Show).clr_members.each { |m| puts m.to_string } It should print Void Show() Void Show(System.Windows.Forms.IWin32Window) Tomas From: ironruby-core-bounces at rubyforge.org<mailto:ironruby-core-bounces at rubyforge.org> [mailto:ironruby-core-bounces at rubyforge.org<mailto:ironruby-core-bounces at rubyforge.org>] On Behalf Of Meinrad Recheis Sent: Sunday, February 08, 2009 10:55 AM To: ironruby-core Subject: [Ironruby-core] cannot initialize Form with IronRuby IronRuby 1.0.0.0 on .NET 2.0.50727.1433 Copyright (c) Microsoft Corporation. All rights reserved.>>> require "System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"=> true>>> Form = System::Windows::Forms::Form=> System::Windows::Forms::Form>>> f=Form.new=> #<System::Windows::Forms::Form:0x000005c>>>> f.Show():0: wrong number of arguments (2 for 3) (ArgumentError)>>> f.method( :Show).arity=> 0>>>This is the latest daily DLR build on codeplex from 2009 Feb 1 at 9:36 PM. I read, that with older versions winforms interop has already been working. -- henon _______________________________________________ Ironruby-core mailing list Ironruby-core at rubyforge.org<mailto:Ironruby-core at rubyforge.org> http://rubyforge.org/mailman/listinfo/ironruby-core -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://rubyforge.org/pipermail/ironruby-core/attachments/20090208/b0ae809b/attachment-0001.html>
Meinrad Recheis
2009-Feb-09 00:42 UTC
[Ironruby-core] cannot initialize Form with IronRuby
On Mon, Feb 9, 2009 at 1:14 AM, Tomas Matousek <Tomas.Matousek at microsoft.com> wrote:> I fixed this on Friday J > > > > The problem was that Show() declared on Control was hidden by > Show(IWin32Window) on Form. It took me a while to make it work J. See > http://rubyforge.org/pipermail/ironruby-core/2009-February/003752.html > >I see. I notice, that there is still heavy development going on. Sadly, in the latest head there are System.Action<T, ... >and System.Func<T, ....> definitions in Microsoft.Scripting.Core.dll that clash with the same definitions in System.Core.dll which I need because of Hashset<T>. How can that problem be resolved? Error 23 The type ''System.Func<TResult>'' exists in both ''d:\Program Files\Reference Assemblies\Microsoft\Framework\v3.5\System.Core.dll'' and ''..\Microsoft.Scripting.Core.dll'' -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://rubyforge.org/pipermail/ironruby-core/attachments/20090209/85a0be1e/attachment.html>
You can define a global alias for System.Core.dll: right-click on the reference in project, select properties, write "SysCore" to "Aliases" field, add "extern alias SysCore;" on top of your C# source file and use "SysCore::" prefix for System.Core namespaces. See also http://devhawk.net/2008/10/21/The+Fifth+Assembly.aspx. Tomas From: ironruby-core-bounces at rubyforge.org [mailto:ironruby-core-bounces at rubyforge.org] On Behalf Of Meinrad Recheis Sent: Sunday, February 08, 2009 4:42 PM To: ironruby-core at rubyforge.org Subject: Re: [Ironruby-core] cannot initialize Form with IronRuby On Mon, Feb 9, 2009 at 1:14 AM, Tomas Matousek <Tomas.Matousek at microsoft.com<mailto:Tomas.Matousek at microsoft.com>> wrote: I fixed this on Friday :) The problem was that Show() declared on Control was hidden by Show(IWin32Window) on Form. It took me a while to make it work :). See http://rubyforge.org/pipermail/ironruby-core/2009-February/003752.html I see. I notice, that there is still heavy development going on. Sadly, in the latest head there are System.Action<T, ... >and System.Func<T, ....> definitions in Microsoft.Scripting.Core.dll that clash with the same definitions in System.Core.dll which I need because of Hashset<T>. How can that problem be resolved? Error 23 The type ''System.Func<TResult>'' exists in both ''d:\Program Files\Reference Assemblies\Microsoft\Framework\v3.5\System.Core.dll'' and ''..\Microsoft.Scripting.Core.dll'' -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://rubyforge.org/pipermail/ironruby-core/attachments/20090208/2411ff7b/attachment.html>