// Set constraint As Late As Possible for task with Id 11 System::SharedPtr wallBoard = project1->get_RootTask()->get_Children()->GetById(11); wallBoard->Set(Tsk::ConstraintType(), Aspose::Tasks::ConstraintType::AsLateAsPossible); // Save project as pdf System::SharedPtr options = System::MakeObject(); options->set_StartDate(project1->Get(Prj::StartDate())); options->set_Timescale(Aspose::Tasks::Visualization::Timescale::ThirdsOfMonths); project1->Save(dataDir + u"project_AsLateAsPossible_out.pdf", options);