This PowerShell script uses the adTempus API to retrieve a File Server definition and set a new password for it.
Usage:
.\set-ADTFileServerPassword -fileServer serverName -newpassword password
This PowerShell script uses the adTempus API to retrieve a File Server definition and set a new password for it.
Usage:
.\set-ADTFileServerPassword -fileServer serverName -newpassword password
This script can be run by an adTempus script task to set a Job Variable to the last business day of the month prior to when the script is run.
It sets the job variable "LastBusinessDayOfPriorMonth" to this date in yyyy-MM-dd format.
The script excludes Saturdays, Sundays, and holidays when looking for the last business day.
There are three versions:
This script can be used if you want to trigger a job using a file and set Job Variables from values in the file.
To use the script, create a new Shared Script in adTempus using C# as the language and this script as the script body. In your job, configure the File Trigger as normal and add a Script Execution Task as the first step of the job to run the Shared Script.
The script gets the name of the trigger file, reads it, and sets the variables.
//Connect to the local adTempus server, using Windows authentication. | |
using (var connection = Scheduler.Connect()) | |
{ | |
//Create a DataContext to work in. All object operations take place within this context. | |
//Use a Using block so the context is disposed when we finish with it | |
using (var context = connection.NewDataContext()) | |
{ | |
//Fetch the job named "My Test Job" | |
var job = context.GetJob("My Test Job"); | |
if (null == job) |
This SQL script lists the names and addresses of all Notification Recipients used by Notification Actions in Responses defined for Jobs and Job Steps and for Notification Tasks within jobs.
This PowerShell script uses the adTempus API to retrieve a Credential Profile and set a new password for it.
Usage:
.\set-adtcredentialpassword -account userid -newpassword password
This fragment demonstrates how to add a mapped network drive to a job
This code creates a NetworkConnection resource to map a drive letter to a UNC path for use within the job.
param ( | |
[string]$server = ".", | |
[string]$job = "*", | |
[datetime]$start=, | |
[datetime]$end, | |
[Parameter(Mandatory)] | |
[string]$output | |
) | |
add-type -path "c:\program files\arcana development\adtempus\4.0\ArcanaDevelopment.adTempus.Client.dll" |
This sample demonstrates how to use the adTempus API from Python.
The adTempus API is only available as a .NET assembly, but can be referenced from Python by using Python.NET.
Refer to the Python.NET documentation for installation instructions. Once Python.NET is installed, your Python code can reference the adTempus client assembly as shown below.
This script demonstrates how to retrieve a Holiday Set and get a list of the holiday dates that it defines