<HTML><BODY>
<DIV>Thanks for all the answer but I try, for example whit:</DIV>
<DIV><BR>folderToDelete = 'toDelete'<BR>
container.manage_delObjects([folderToDelete])<BR><BR>#or<BR><BR>
container.manage_delObjects([container[folderToDelete].getId()])<BR><BR>and
get the following error in both cases:<BR>Error Type: KeyError<BR>Error
Value: toDelete<BR><BR>---------------------------<BR>and the "really"
traceback is:<BR><BR>Traceback (innermost last):<BR> Module
ZPublisher.Publish, line 101, in publish<BR> Module
ZPublisher.mapply, line 88, in mapply<BR> Module
ZPublisher.Publish, line 39, in call_object<BR> Module
Shared.DC.Scripts.Bindings, line 306, in __call__<BR> Module
Shared.DC.Scripts.Bindings, line 343, in _bindAndExec<BR> Module
Products.PythonScripts.PythonScript, line 323, in _exec<BR>
Module None, line 27, in update<BR> -
<PythonScript at
/approach/SiccApproach/Configuration/AuthenticationTypes/update><BR>
- Line 27<BR> Module Shared.DC.Scripts.Bindings,
line 306, in __call__<BR> Module Shared.DC.Scripts.Bindings, line
343, in _bindAndExec<BR> Module
Products.PageTemplates.ZopePageTemplate, line 222, in _exec<BR>
Module Products.PageTemplates.PageTemplate, line 96, in
pt_render<BR> - <ZopePageTemplate at
/approach/SiccApproach/Configuration/AuthenticationTypes/update_html><BR>
Module TAL.TALInterpreter, line 190, in __call__<BR>
Module TAL.TALInterpreter, line 234, in interpret<BR>
Module TAL.TALInterpreter, line 291, in do_startTag<BR>
Module TAL.TALInterpreter, line 357, in attrAction_tal<BR>
Module Products.PageTemplates.TALES, line 227, in
evaluateText<BR> Module Products.PageTemplates.TALES, line 221,
in evaluate<BR> - URL:
/approach/SiccApproach/Configuration/AuthenticationTypes/update_html<BR>
- Line 56, Column 13<BR> - Expression:
<PythonExpr
container[request['autType']][request['autType']+'AuthType'].function()><BR>
- Names:<BR> {'container': <Folder
instance at 430bbc80>,<BR> 'context':
<Folder instance at 430bbc80>,<BR>
'default': <Products.PageTemplates.TALES.Default instance at
0x40aa4c6c>,<BR> 'here': <Folder instance at
430bbc80>,<BR> 'loop': <SafeMapping instance
at 40ac2f90>,<BR> 'modules':
<Products.PageTemplates.ZRPythonExpr._SecureModuleImporter instance at
0x40aa92ec>,<BR> 'nothing': None,<BR>
'options': {'args': (),<BR>
'msg': 'Usted ha tenido
suerte, el servidor est\xe1 prendido y se ha podido modificar'},<BR>
'repeat': <SafeMapping instance at
40ac2f90>,<BR> 'request': <HTTPRequest,
URL=<A class=fixed
href="http://ceismail.cujae.edu.cu/horde/util/go.php?url=http%3A%2F%2F172.16.13.105%3A9673%2Fapproach%2FSiccApproach%2FConfiguration%2FAuthenticationTypes%2Fupdate&Horde=94e5350a58712b744da9c44601b6bfad"
target=_blank>
http://172.16.13.105:9673/approach/SiccApproach/Configuration/AuthenticationTypes/update</A>
>,<BR> 'root': <application instance at
43001b30>,<BR> 'template': <ZopePageTemplate
at
/approach/SiccApproach/Configuration/AuthenticationTypes/update_html>,<BR>
'traverse_subpath': [],<BR>
'user': leticia}<BR> Module
Products.PageTemplates.ZRPythonExpr, line 47, in __call__<BR> -
__traceback_info__:
container[request['autType']][request['autType']+'AuthType'].function()<BR>
Module Python expression
"container[request['autType']][request['autType']+'AuthType'].function()",
line 1, in <expression><BR> Module
AccessControl.ZopeGuards, line 67, in guarded_getitem<BR> Module
OFS.ObjectManager, line 663, in __getitem__<BR>KeyError: 'adminSiccDB34'<BR>
<BR><BR>-----Original Message-----<BR>From: Dieter Maurer
<dieter@handshake.de><BR>To: "Leticia Larrosa"
<LETICIA@tesla.cujae.edu.cu><BR>Cc: zope@zope.org<BR>Date: Wed, 23 Mar
2005 20:16:15 +0100<BR>Subject: Re: [Zope] manage_delObjects()<BR><BR>>
Leticia Larrosa wrote at 2005-3-23 12:37 -0400:<BR>> > ...<BR>>
>"manage_delObjects", example:<BR>> >folderToDelete =
"exampleFolder"<BR>>
>container.manage_delObjects([container[folderToDelete]])<BR>>
>#or<BR>> >container.manage_delObjects([getattr(container,
folderToDelete)])<BR>> >----------------------------<BR>> >I get
the following error:<BR>> >Error Type: AttributeError<BR>>
>Error Value: __getslice__<BR>> <BR>> You pass in the object itself
-- but you should pass its id.<BR>> <BR>> Thus, the following will
probably work:<BR>> <BR>>
container.manage_delObjects([folderToDelete])<BR>> <BR>> -- <BR>>
Dieter<BR>> _______________________________________________<BR>> Zope
maillist - Zope@zope.org<BR>>
http://mail.zope.org/mailman/listinfo/zope<BR>> ** No cross posts
or HTML encoding! **<BR>> (Related lists - <BR>>
http://mail.zope.org/mailman/listinfo/zope-announce<BR>>
http://mail.zope.org/mailman/listinfo/zope-dev )<BR>> <BR>> <BR>
</DIV>
</BODY></HTML>