View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0005782 | JEDI VCL | 00 JVCL Components | public | 2012-02-02 22:31 | 2013-12-13 11:25 |
Reporter | limagito | Assigned To | obones | ||
Priority | normal | Severity | block | Reproducibility | always |
Status | resolved | Resolution | suspended | ||
Product Version | 3.45 | ||||
Target Version | Fixed in Version | ||||
Summary | 0005782: JVScheduledevents doesn't load all settings after Revision 11163 | ||||
Description | After revision JVScheduledEvents doesn't load all settings anymore. The error is located in the TJvEventCollectionItem.Loadstate procedure. | ||||
Additional Information | They left out the following code since 11163 and since then it doesn't load the End Type Settings anymore. Schedule.StartDate := AStartDate; Schedule.EndType := AEndType; if ARecurringType = srkOneShot then begin Schedule.EndType := sekDate; Schedule.EndDate := AStartDate; IDayFrequency := Schedule as IJclScheduleDayFrequency; with IDayFrequency do begin StartTime := AStartDate.Time; EndTime := AEndDate.Time; Interval := 1; end; end else begin Case Schedule.EndType of sekDate: Schedule.EndDate := AEndDate; sekTriggerCount: Schedule.EndCount:= AEndCount; sekDayCount: Schedule.EndCount:= AEndCount; end; | ||||
Tags | No tags attached. | ||||
|
Please provide the zipped sources of a sample application showing this |
2012-04-01 13:57
|
JvScheduledEvents.pas (59,197 bytes) |
|
Hi, I've just uploaded a working version of JvScheduledEvents.pas 1) I found another bug. There was some code that was comment in revision 11163 (and older). Someone removed the comment (* *), NOT GOOD. I think it's better to remove this part complete. If this code is uncommented then the start of the schedules are completely wrong. This is done in the .Start Procedure. Don't do it twice. procedure TJvEventCollectionItem.LoadState (* if IsNullTimeStamp(NextFire) or (CompareTimeStamps(NextFire, DateTimeToTimeStamp(Now)) < 0) then Schedule.NextEventFromNow(CountMissedEvents); if IsNullTimeStamp(NextFire) then FState := sesEnded else FState := sesWaiting; *) 2) I've changed the .start procedure, no exception but Exit when already started. procedure TJvEventCollectionItem.Start; begin if FState in [sesTriggered, sesExecuting] then Exit; 3) Removed the exception handling in the Try Except End; of the .CMExecEvent Procedure (identical as it is handled in the procedure TScheduleThread.Execute;). procedure TJvCustomScheduledEvents.CMExecEvent(var Msg: TMessage); begin with Msg do try DoStartEvent(TJvEventCollectionItem(WParam)); TJvEventCollectionItem(WParam).Execute; DoEndEvent(TJvEventCollectionItem(WParam)); Result := 1; except End end; Best Regards, Pascal |
|
Thanks for that but I still need a demo application to see the issue. |
|
No news, suspending the issue |
Date Modified | Username | Field | Change |
---|---|---|---|
2012-02-02 22:31 | limagito | New Issue | |
2012-02-22 15:07 | obones | Note Added: 0019463 | |
2012-02-22 15:07 | obones | Status | new => feedback |
2012-04-01 13:57 | limagito | File Added: JvScheduledEvents.pas | |
2012-04-01 14:14 | limagito | Note Added: 0019685 | |
2012-06-11 17:40 | obones | Note Added: 0019875 | |
2013-12-13 11:25 | obones | Note Added: 0020775 | |
2013-12-13 11:25 | obones | Status | feedback => resolved |
2013-12-13 11:25 | obones | Resolution | open => suspended |
2013-12-13 11:25 | obones | Assigned To | => obones |