ProjectServerSaveOptions.PollingInterval
Contents
[
Hide
]ProjectServerSaveOptions.PollingInterval property
Gets or sets interval between queue job status requests. The default value is 2 seconds.
public TimeSpan PollingInterval { get; set; }
Examples
Shows how to use <see cref=“Aspose.Tasks.ProjectServerSaveOptions” /> options to create a new project in on-premise instance of Project Server.
try
{
const string URL = "https://project_server.local/sites/pwa";
const string Domain = "CONTOSO.COM";
const string UserName = "Administrator";
const string Password = "MyPassword";
var project = new Project(DataDir + @"Project1.mpp");
var windowsCredentials = new NetworkCredential(UserName, Password, Domain);
var projectServerCredentials = new ProjectServerCredentials(URL, windowsCredentials);
var manager = new ProjectServerManager(projectServerCredentials);
var options = new ProjectServerSaveOptions
{
ProjectGuid = Guid.NewGuid(),
ProjectName = "New project",
Timeout = TimeSpan.FromMinutes(5),
PollingInterval = TimeSpan.FromSeconds(3)
};
manager.CreateNewProject(project, options);
}
catch (ProjectOnlineException ex)
{
Console.WriteLine(ex.Message);
}
See Also
- class ProjectServerSaveOptions
- namespace Aspose.Tasks
- assembly Aspose.Tasks