Hello,
I created a model with about 3500 components(beams and shells). Since I use the com-interface, each component gets it's own group. Importing the model with those components works perfectly fine. But when I try to create the respective groups, the first 1122 groups can be created and after that I receive an error. This error is probably a memory error. The component can be added and removed to/from the group using "ComponentMembership". However "group.Components.Count()" and "group.Components.Key(<keyname>)" does not return a component as can be seen in the following code. The last line (Error #3035) says "not enough Memory" in German. What can I do? (An image of the model is attached)
g=self.hsProject.Groups.Key(10000)
g
<win32com.gen_py.HyperSizer Advanced Structural Analysis Library, v6.4._Group instance at 0x364587928>
g.ComponentMembership([756075],[0])
True
g.GroupMembershipComponentList()
(756075,)
g.Components.Key(756075)
Traceback (most recent call last):
File "C:\Eclipse\eclipse\plugins\org.python.pydev_2.7.1.2012100913\pysrc\pydevd_comm.py", line 765, in doIt
result = pydevd_vars.evaluateExpression(self.thread_id, self.frame_id, self.expression, self.doExec)
File "C:\Eclipse\eclipse\plugins\org.python.pydev_2.7.1.2012100913\pysrc\pydevd_vars.py", line 376, in evaluateExpression
result = eval(compiled, updated_globals, frame.f_locals)
File "<string>", line 1, in <module>
File "C:\Python27\lib\site-packages\win32com\gen_py\36A23079-251A-43B3-8FE8-DB5E1FDAF0A6x0x7x0.py", line 1811, in Key
ret = self._oleobj_.InvokeTypes(1745027083, LCID, 2, (9, 0), ((8, 1),),ComponentKey
com_error: (-2147352567, 'Ausnahmefehler aufgetreten.', (0, u'ComponentCol', u'Project Component Not Found', None, 1000440, -2147188693), None)
g.Components.Count()
0
g.ComponentMembership([0],[756075])
True
g.GroupMembershipComponentList()
()
g.ComponentMembership([756075],[0])
True
g.GroupMembershipComponentList()
(756075,)
g.Components.Count()
Traceback (most recent call last):
File "C:\Eclipse\eclipse\plugins\org.python.pydev_2.7.1.2012100913\pysrc\pydevd_comm.py", line 765, in doIt
result = pydevd_vars.evaluateExpression(self.thread_id, self.frame_id, self.expression, self.doExec)
File "C:\Eclipse\eclipse\plugins\org.python.pydev_2.7.1.2012100913\pysrc\pydevd_vars.py", line 376, in evaluateExpression
result = eval(compiled, updated_globals, frame.f_locals)
File "<string>", line 1, in <module>
File "C:\Python27\lib\site-packages\win32com\gen_py\36A23079-251A-43B3-8FE8-DB5E1FDAF0A6x0x7x0.py", line 1777, in Count
return self._oleobj_.InvokeTypes(1610809367, LCID, 1, (3, 0), (),)
com_error: (-2147352567, 'Ausnahmefehler aufgetreten.', (0, u'Components [Property Get]', u'Unhandled Error, Application Error in ComponentCol::Components [Property Get]()\r\n\r\nLine #7, Error #-2147188733, Unhandled Error, Application Error in clsComponent::Init [Sub]()\r\n\r\nLine #7, Error #3035, Nicht gen\xfcgend Arbeitsspeicher.', None, 1000440, -2147188733), None)