ASP.NET VETtrak API web services
ContentsIndexHome
PreviousUpNext
VT_API.GetWebLocationsForProgrammeAndDates Method

Gets a list of locations for web-published occurrences with available places, that are for a specified programme and/or start in a specified date range. 

You can use this function to give a user a list of available locations to filter by. After the user selects a location, you can call SearchWebOccurrences to find details of occurrences with that location. 

Either a programmeId, or a startDate and endDate, or both, need to be specified. 

You can use GetWebProgrammes, GetWebProgrammesForDates, GetWebProgrammesForProgType or GetWebProgrammesForProgTypeAndDates to find a programmeId to filter by. 

The test for web occurrence start date, being within the date range, is inclusive of end points. 

Available places means that the number of students enrolled is less than the maximum number allowed for the occurrence. 

Each location item is represented by a TLoca. The collection of locations is represented by a List of TLoca

A token is passed for authentication. If the authentication fails, or other errors occur, no locations are returned. The result of the authentication is represented by a TAuthenticate object. 

Requires a valid registration key entry for the Short Courses feature. 

This function has security level "Protected", and can only be accessed by users that have explicitly been granted permission to the API.

C#
[WebMethod(Description = "Gets a list of locations with a web-enabled occurrence in the specified programme and/or date range that has available places")]
public TAuthLocaList GetWebLocationsForProgrammeAndDates(string token, int? programmeId, DateTime? startDate, DateTime? endDate);
Parameters 
Description 
string token 
String containing a token. 
int? programmeId 
Optional integer ID of the programme to find occurrences for. Specify null or 0 to not filter on programme. 
DateTime? startDate 
Optional DateTime, start of date range in which to find occurrences starting. If this is specified, endDate must also be specified. Specify null, for both this and endDate, to not filter on date. 
DateTime? endDate 
Optional DateTime, end of date range in which to find occurrences starting. If this is specified, startDate must also be specified. Specify null, for both this and startDate, to not filter on date. 

TAuthLocaList list of locations of web published occurrences with available places matching the specified criteria

Copyright (c) VETtrak 2022. All rights reserved.