- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hi.
Could you help me choose the most efficient way to loop through high amount of components in assembly file? For now I am doing it using classic For Each loop, but it takes almost 10 seconds to loop through 100 subassemblies and their subcomponents on pretty good computer. Maybe duration of loop execution is so long because I am looping through multiple COM objects?
In most cases I need to find some components or subcomponents depending on their iProperties, Parameters, Name, special features etc. To do it I am executing a For Each loop with If-Else statements inside it to compare current loop occurrence with target occurrence.
I am not very familiar with high-level programming solutions and for now I will be happy if I find a general concept. Maybe external database in which subassemblies and subcomponents are stored as strings (only their name) will be a better idea?
Solved! Go to Solution.