How get Event Frames which do have End time in it by using AF.SDK. Please share the code here
IIRC, open event frames ( without an end) return an end time at the end of the year 9999. So you can simply search for those with an end time before that.
Edit: Oops, there is an explicit search for that: Use 'InProgress:False' in the search query
You can use the example posted in the documentation and adjust it.
Is there any direct method for getting events which does not have end time.
Use the example and adjust it:
// Search for EventFramesAFNamedCollectionList<AFEventFrame> list = AFEventFrame.FindEventFrames(myDB, null, AFTime.Now, 0, 200, AFEventFrameSearchMode.BackwardFromStartTime, null, null, null, null, false);
// Search for EventFrames
AFNamedCollectionList<AFEventFrame> list = AFEventFrame.FindEventFrames(myDB, null, AFTime.Now, 0, 200, AFEventFrameSearchMode.BackwardFromStartTime, null, null, null, null, false);
Event Frames that do not have an end time are not close, or rather are "in progress". So you can use the search query: 'InProgress:True'
Please share the method which will provide all events frames with e.g.
The best practice would be to use the AFEventFrameSearch class that derives from the abstract AFSearch class. Many of the other Event Frame search methods are obsolete and are not as performant as the newest search classes.
AFSearchMode needs to be AFSearchMode.Inprogess
Set the startTime to AFTime.MinValue and the endTime to AFTime.MaxValue. I would avoid dealing with the year 9999 and just use static fields AFTime.MaxValue.
There is a pretty good example here. Note, the example is not using search tokens but using a query string.
Retrieving data ...