Page 1 of 1

Error "(10,8):StartBoundary:." with 2.0.14.0

Posted: Sat Dec 05, 2015 1:23 pm
by AlexD
Hello,

I've just installed VCL Scheduling Agent 2.0.14.0 and am receiving the error "(10,8 ):StartBoundary:." in unit "saTask", function "TTaskItem.SetAccountInformation" in pRegisteredTask := itf.RegisterTaskDefinition(Name, FTaskDefinition, TASK_CREATE_OR_UPDATE, '', '', FTaskDefinition.Principal.LogonType, '');

I'm using Delphi XE7 Update 1 on Win 8.1 64bit on a VM. VM shouldn't be a problem as older versions were working fine on a VM.

I had the trial version installed prior to the full version and there the same error was occurring. I'd uninstalled it before installing the full version.

What can be done to fix it?

Best regards,
Alex

Posted: Sun Dec 06, 2015 1:09 pm
by isiticov
Do you use ttOnce trigger? If you do - have you initialized TriggerDetails field?

(http://www.sicomponents.com/forum/viewt ... =3693#3693)

Posted: Sun Dec 06, 2015 1:46 pm
by AlexD
No, I'm using ttDaily trigger.

Here is the code:

Code: Select all

      Task := TaskScheduler1.CreateNewItem(TaskName + IntToStr(Number));
      Task.CurrentAction := 1;
      Task.InsertAction(VISTA_TASK_ACTION_EXEC);
      Task.ApplicationName := Application.ExeName;
      Task.Parameters := <some_parameters>;
      Task.WorkingDirectory := <some_path>;
      Task.Triggers.Add(ttDaily);
      if (not TaskScheduler1.RunningVistaOrLater) then begin
         Task.Flags := Task.Flags + [tfRunOnlyIfLoggedOn];
      end
      else begin
         Task.SetVistaFlag(tfvEnabled, True);
      end;
      Task.SetAccountInformation(GetOSUser, '');
Going with the hint from the other thread I've added

Code: Select all

      tmpTriggerDetails.Daily.DaysInterval := 1;
      Task.Triggers[0].Details := tmpTriggerDetails;
      Task.Triggers.UpdateTriggers;
after adding the trigger and it seems to work now. Something must have changed since 2.0.8.0, which is being used in an older project.

Thanks for the hint.