Thanks for this Mathieu, the script which creates the folder under the inbox works good. To create it in the root must be a little more complex because this doesnt work yet. When I fire up the script it prompts me with the following error:
Error: Object doesnt support this property or method: 'olApp.GetNamespace(...).Folder' Code: 800A01B6 Can you point me in the right direction to solve this? Cheers, Victor -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Mathieu CHATEAU Sent: maandag 28 augustus 2006 11:26 To: [EMAIL PROTECTED] Cc: ActiveDir@mail.activedir.org Subject: Re[2]: [ActiveDir] Add folder with quota to existing mailboxes - via scripting or tool this script goes through outlook. Each user need to fire this script (or fire it via logon script). for the Root Folder, change: set inbox = olApp.GetNamespace("MAPI").getDefaultFolder(6) to set inbox = olApp.GetNamespace("MAPI").Folder("Personal Folder") (should do the trick but i didn't test it yet) Regards, Mathieu CHATEAU http://lordoftheping.blogspot.com Monday, August 28, 2006, 11:00:14 AM, you wrote: vwpn> Thanks Brian and Mathieu, vwpn> I will tell a little bit more about the background of this. The vwpn> customer has asked for a folder called "private" to be created in vwpn> the root of every users mailbox and if possible set a quota to this folder. vwpn> After this has been done, the customer wants to instruct his users vwpn> to use only this folder only as their personal/private email vwpn> folder and move everything that the users sees as being private, vwpn> to the private folder. From that moment on, all other folders in vwpn> the users mailboxes are no longer considered as private/personal. vwpn> I do have some additional questions: vwpn> - how would the script look if the requirement would be to create vwpn> the folder in the root. vwpn> - The way the script is set up now, do I have to set up which vwpn> users this script will apply to, I mean will it now apply to all vwpn> users in the entire domain which are mailbox enabled? vwpn> - Is there any way that I can specify which users this script has vwpn> to be applied to, I mean can I run it against all mailbox enabled vwpn> users in a specific OU? vwpn> ------------------------------------------------------------------ vwpn> ------ vwpn> ------- vwpn> Re[2]: [ActiveDir] Add folder with quota to existing mailboxes - vwpn> via scripting or tool vwpn> From: Mathieu CHATEAU <[EMAIL PROTECTED]> vwpn> Date: Mon, 28 Aug 2006 00:24:47 +0200 vwpn> ------------------------------------------------------------------ vwpn> ------ vwpn> -------- vwpn> Hello Victor, vwpn> If the folder already exist, it will simply do nothing, except vwpn> going into errors.. vwpn> need to add a on error resume next or test if the folder exist before. vwpn> will create in the inbox, as a subfolder vwpn> I don't see your goal with this folder...except if you turn vwpn> special rights on it. vwpn> may ask them to put it [private] in the subject instead (it will vwpn> work for the sent folders) vwpn> Regards, vwpn> Mathieu CHATEAU vwpn> http://lordoftheping.blogspot.com vwpn> Sunday, August 27, 2006, 10:26:59 PM, you wrote: vwpn> Thanks Mathieu, nice. vwpn> Does this create a folder in the root of the mailbox? vwpn> vwpn> Access all mailboxes you say, that sounds logical. I know that vwpn> domain admins indeed dont actually have the full mailbox access vwpn> (they have some denies). vwpn> What if a user already has the folder, does this script take this vwpn> into account? vwpn> Again thanks. vwpn> Victor vwpn> From: Mathieu CHATEAU [mailto:[EMAIL PROTECTED] vwpn> Sent: zondag 27 augustus 2006 22:04 vwpn> To: Victor W. vwpn> Cc: [EMAIL PROTECTED] vwpn> Subject: Re: [ActiveDir] Add folder with quota to existing vwpn> mailboxes - via scripting or tool vwpn> Hello Victor, vwpn> you will at least need an account that can access all mailboxes vwpn> (not a domain admins one) vwpn> (or give a script to everyone that they will execute) vwpn> To my knowledge, quota is mailbox based. You may set up a special vwpn> retention on this folder. vwpn> sample _vbscript_ to create the private folder vwpn> set olApp = CreateObject("Outlook.Application") vwpn> set inbox = olApp.GetNamespace("MAPI").getDefaultFolder(6) vwpn> set temp5 = inbox.folders.add("Private",6) vwpn> hope it helps, vwpn> Regards, vwpn> vwpn> Mathieu CHATEAU vwpn> http://lordoftheping.blogspot.com vwpn> Sunday, August 27, 2006, 8:57:03 PM, you wrote: vwpn> Does anybody know what is the 'best' way to add vwpn> automatically a folder to existing mailboxes and set a quota on vwpn> that same folder? vwpn> We would like all our users to get a folder called vwpn> "private" added to the root of their mailbox and if possible, a vwpn> quota to be set to that folder. vwpn> Can this be done by scripting easily or is there perhaps vwpn> even a tool which is capable of doing this? vwpn> This also counts for new, still to be created users. I mean, every vwpn> user that will be created will have to have that certain folder vwpn> added to his or her mailbox. vwpn> Offcourse this could be done by running the script a vwpn> couple of times a day, checking if the folder exists allready and vwpn> if not, adding it. Or perhaps it can even by realised the vwpn> moment a user has been created. vwpn> vwpn> Any ideas are greatly appreciated. vwpn> List info : http://www.activedir.org/List.aspx vwpn> List FAQ : http://www.activedir.org/ListFAQ.aspx vwpn> List archive: http://www.activedir.org/ml/threads.aspx List info : http://www.activedir.org/List.aspx List FAQ : http://www.activedir.org/ListFAQ.aspx List archive: http://www.activedir.org/ml/threads.aspx List info : http://www.activedir.org/List.aspx List FAQ : http://www.activedir.org/ListFAQ.aspx List archive: http://www.activedir.org/ml/threads.aspx