Grasshopper

algorithmic modeling for Rhino

"You cannot call IGN_DataAccess.GetDataList() on an Item Parameter"

I'm getting "You cannot call IGN_DataAccess.GetDataList() on an Item Parameter"

 and I have DA.GetDataList, I'm going crazy.

 

But I have included GH_ParamAccess.list in the code below, what is going on.....

 

 


Protected Overrides Sub RegisterInputParams(ByVal pManager AsGrasshopper.Kernel.GH_Component.GH_InputParamManager)

 

 

pManager.Register_MeshParam("Mesh", "meshObject", "Mesh To Export",GH_ParamAccess.list)

 

End Sub

 

 


 

 Protected Overrides Sub SolveInstance(ByVal DA As Grasshopper.Kernel.IGH_DataAccess)

 

 

Dim meshObject As New List(Of Rhino.Geometry.Mesh)


If (Not DA.GetDataList(0, meshObject)) Then Return


Views: 371

Replies to This Discussion

Are you creating a brand new component on the canvas?  If it is a component that was saved with a previous version of the component that wasn't extracting a list you will still get this error message when opening the grasshopper document.  Delete it and try adding it again.
Hmm, does it retain a preferences list of components, that I can delete, I tried deleting it and adding it, that does not work, I'll try it though
Should I change the System.guid to something else?
OK that worked, what the hell....... I generated a brand new GUID yesterday, how can this be the problem...... does grasshopper retain guid ids in a preference file?

I can't see anything wrong with your code and the symptom matched what I've seen in the past with this.  Changing the guid would certainly force you to replace the component.

 

I pasted your code into this sample component that worked fine for me.

Attachments:
Thanks once again Jon for the advice, much appreciated :)

RSS

About

Translate

Search

Videos

  • Add Videos
  • View All

© 2024   Created by Scott Davidson.   Powered by

Badges  |  Report an Issue  |  Terms of Service