cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

iLogic/API: Toggle visibility of multiple Parts List rows at once

iLogic/API: Toggle visibility of multiple Parts List rows at once

Currently, if we want to toggle the visibility of several rows in a Parts List via the API, we have to iterate through them and toggle them one by one. There is a noticeable performance hit for each row. Processing just a few dozen rows takes several seconds.

 

There should be a way to toggle the visibility of several specified rows at once via the API, as we can via the Parts List editor window. It would be nice to have a method for explicitly setting a collection of rows to Visible or Invisible, as well as a method for toggling a collection of rows (visible becomes invisible, invisible becomes visible).

 

Related thread on Inventor forum: iLogic: Speed up performance of toggling Parts List row visibility

1 Comment
arkadiusz.budkowski
Participant

Hi,

There should also be like ".hideAll()". I have 2000 rows in my partslist and i want to show only 200 of them. Hiding by ".Visible = False" is ultra slow. With hideAll() i could hide them first and then loop through to show those which i want. Faster to set visible = True to 200 parts than hide 1800.

 

Also it would be great to have ".Item(x).hideIf("String")" / ".Item(x).hideIfNot("String")". It would make code cleaner as i could in one line hide all element which does not have some string like "mystr" in some cell (Cell found by .Item(x))

Can't find what you're looking for? Ask the community or share your knowledge.

Submit Idea