Grasshopper

algorithmic modeling for Rhino

That's the point. I can get MSVS working at all. I have follow every step in Ben Sitler guide but it doesn't work.

When I paste the VB first example code in MSVS everythings ok but I got some errors that didn´t let me Build the dll file in the bin/release folder.

Error 1 'Register_Boolean' is not a member of 'Grasshopper.Kernel.GH_Component.GH_InputParamManager'. E:\Visual Studio 2008\Projects\Prueba\Prueba\Class1.vb 16 9 Prueba

Error 2 Overload resolution failed because no accessible 'GetData' can be called with these arguments:    'Public Function GetData(Of Grasshopper.Kernel.Types.GH_Boolean)(name As String, ByRef destination As Grasshopper.Kernel.Types.GH_Boolean) As Boolean': Value of type 'Boolean' cannot be converted to 'Grasshopper.Kernel.Types.GH_Boolean'.    'Public Function GetData(Of Grasshopper.Kernel.Types.GH_Boolean)(index As Integer, ByRef destination As Grasshopper.Kernel.Types.GH_Boolean) As Boolean': Value of type 'Boolean' cannot be converted to 'Grasshopper.Kernel.Types.GH_Boolean'. E:\Visual Studio 2008\Projects\Prueba\Prueba\Class1.vb 26 13 Prueba

Error 1 is easy to get in silent changing Register_Bollean to Register_BolleanParam. But I don't know if this is the correct solution.

I have no idea about Error 2 :S

Anyone knows? It's my first time debuggin in visual studio :)

Views: 696

Replies to This Discussion

Angel, have you looked at David's example in the GH SDK? You can find then in the GH_SDK (Under the help menu in Grasshopper). See if following those gives you different results. How are you setting up the variables to grab the data?
Hey,

Thanx Luis! I need to look GH_SDK example.

I'm ussing Rhino 5 64bits and GH 0.60059. At today, 0.7 doesn't give me good sensations because the bugs...but I know that I'll need to learn the new Rhino.Common in future.

What means "settings variables to grab the data"? It's my first time going out of Monkey or Grasshopper to make plugins or scripts :S

Thanks for your usefull help :)

Best.
What I mean by how you are setting up the variables...
for example to get a boolean from the 3rd registered input:

In register parameters:
pManager.Register_BooleanParam("Flip", "f", "Flip Value", False, GH_ParamAccess.item)
pManager(3).Optional = True

In Solve Instance:

Dim flip As Boolean = False
If (Not DA.GetData(3, flip)) Then Return

you should check the overloading of the pManager.Register_BooleanParam as I think what I have above would be for an 0.7 component...
Thanks for your answer :) I will look at that.

I'm very excited to play a little bit with custom GH components :D

Best Regards.

Hi Angel,

Which Visual Studio are you guys using to program?

I have never used it...Is there a free version?

http://www.microsoft.com/visualstudio/en-us/

Many thanks,

Arthur

 

Grasshopper is written in Visual Studio 2008, the most recent version is 2010. There are Express editions available which are free.

 

--

David Rutten

david@mcneel.com

Seattle, WA

This is very confusing to a casual. So many versions. Which will be enough? The uni has it all but I'd rather avoid unnecessary complexity. Will VC 2010 Pro with MSDN be OK? I am planning to use VC for a few languages but for simple plugins most of the time.

 

Thank you for the advice.

All you need are the Visual Express Editions (either in C# or VB).  The full version of Visual Studio are great if you have access to them or you have purchased them.  Otherwise, the express editions are free.

Thank you, Luis. I see. Well, as I say - the university here has bulk licenses for all possible versions so it is my choice. Last time I used VS was a few years ago but I vaguely remember that Express has limitation. With debugging?

 

So, if I do have the choice - which to choose?

RSS

About

Translate

Search

Photos

  • Add Photos
  • View All

Videos

  • Add Videos
  • View All

© 2024   Created by Scott Davidson.   Powered by

Badges  |  Report an Issue  |  Terms of Service