[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 240
  • Last Modified:

Help with logon script

Hi

We have a legacy reporting app (Crystal Distribution 8.5) that relies on DLLs to export data from it to other apps such as Excel.

In XP/2003 the DLLs are installed in the WINDOWS & System32 directory but due to changes that MS made in Vista/2008 and higher the DLLS need to be installed in the user's local profile for the app to work properly.  Example:

C:\Users\user.name\WINDOWS\Crystal

This has been easy to manage for the few users on Win 7 workstations but we are now making the move to Server 2008R2 RDS.  Therefore using a script to put these DLLs in the right place via Group Policy when a user logs on to an RDS server (there will be multiple and they will be load balanced) seems the logical answer.

I am not however an expert on scripting by any means.  I can just about manage a logon script to map a network drive.  Could someone help with:

> A logon script that runs once per server per user that I can deploy with a GPO
> The script needs to create a directory in their local user profile path (as previously mentioned) and copy a list of DLLs to it (or just copy the "WINDOWS\Crystal" folder to their local profile).

Many thanks
0
admincbf
Asked:
admincbf
  • 2
1 Solution
 
R. Andrew KoffronCommented:
try adding a path adjustment on login script something like
PATH=%PATH%;C:\WINDOWS\Crystal
0
 
admincbfAuthor Commented:
Hi

I used a Powershell script in the end:

$newfolder = "C:\Users\$env:USERNAME\WINDOWS\"
New-Item -Path $newfolder -ItemType directory #create new folder
copy-item -Path C:\Crystal -Destination $newfolder -Force -Recurse #copy all the files in the folder

Open in new window

0
 
admincbfAuthor Commented:
Precise answer
0

Featured Post

Visualize your virtual and backup environments

Create well-organized and polished visualizations of your virtual and backup environments when planning VMware vSphere, Microsoft Hyper-V or Veeam deployments. It helps you to gain better visibility and valuable business insights.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now