Solved

How do I set folder permissions with VBScript

Posted on 2009-05-15
1
295 Views
Last Modified: 2012-05-07
I have a vb script that removes a desktop shortcut and a Start Menu folder from each colProfile on a workstation
The Good: The script works perfectly on newer builds of XP

The Bad: On older builds the script runs and removes the desktop shortcut but does not remove the Start Menu folder.
I am thinking that with older builds the permissions allowing the current logged on user to modify the Start Menu.
Is there a solution to reset the permissions to allow the script to run. Maybe a VBScript so i can roll it out to about 150 users. All help will be greatly appreciated
0
Comment
Question by:JK-PBS
1 Comment
 
LVL 7

Accepted Solution

by:
LANm0nk3y earned 500 total points
ID: 24400735
If you have the script already, why not have the script run through GPO?  Just make sure you put the new script on in the same folder as your GPO.

Easiest way to do this is, launching Group Policy Managment:
Go under "Group Policy Object", find the policy you are wanting to apply or create a new one.
Edit the policy

Under the policy editor:
Browse down to "Computer Configuration\Policies\Windows\Settings"
You'll see "Startup", doublclick
click "Add", then "Browse"

Open explorer window, browse to your script file, highlight it.  alt-click and copy.  Go back to your "Browse" window, alt-click, paste.

select the file, then click ok, ok.

This will now launch when the computer starts up.  This runs at the computer level, not at user level.  Therefore it will have admin rights to system resources.

Remember if you created another policy, you need to make sure you link the object to the OU (organization units) container that have the computers.
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I met Paul Devereux (@pdevereux) today when I responded to his tweet asking “Anybody know how to automate adding files from disk to a folder in #outlook  ?”.  I replied back and told Paul that using automation, in this case scripting, to add files t…
This article is the result of a quest to better understand Task Scheduler 2.0 and all the newer objects available in vbscript in this version over  the limited options we had scripting in Task Scheduler 1.0.  As I started my journey of knowledge I f…
Exchange organizations may use the Journaling Agent of the Transport Service to archive messages going through Exchange. However, if the Transport Service is integrated with some email content management application (such as an antispam), the admini…

730 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question