SHOUPCLS ​
This version works in Student Manager
Returns a list of upcoming courses. This function was designed for use by MERGMAIL to email course lists to individuals.
Reporting Area(s) ​
Names, Registrations
Required Parameters ​
None
Optional Parameters ​
- Character selection value:
"1" returns courses for the next month (Default)
"2" returns courses for the next 2 months
"3" returns courses for the next 3 months
"4" returns courses for the next 4 months
--OR-- Character string to return courses (e.g. "between(cobegdate,date(),date()+45)" returns courses for the next 45 days)
- Character return string: user defined string to return fields (i.e. "dtoc(cobegdate)+' '+alltrim(cocrsenm)". If nothing is entered, the default is Cocrse+" "+SUBSTR(cocrsenm,1,45)+" "+DTOC(cobegdate)
- Name ID field (in quotations, i.e. "nmid", "rgid")" ONLY returns upcoming courses IF the course subject code is listed in the individual's Interest Code list.
--OR--Condition to return courses based on Course Subject Code (i.e. "cosubcode='COMP'").
- Numeric value - specify the number of days to be added to current date to determine starting reference for date range of courses to be returned.
- Condition to return courses based on field from Course table.
Example(s) ​
SHOUPCLS() returns course number, course title and begin date of all courses that begin within the next month.
SHOUPCLS("3") returns course number, title, and begin date for all courses that begin within the next 3 months
SHOUPCLS("3", "dtoc(cobegdate)+' '+alltrim(cocrsenm)","rgid") returns begin date and course title of courses that begin in the next 3 months IF the subject code is listed in the individual's Interest Code list.
SHOUPCLS("3", "dtoc(cobegdate)+' '+alltrim(cocrsenm)","alltrim(cosubcode) $ 'COMPBUS'") returns begin date and course title of courses that begin in the next 3 months and that have the COMP or BUS subject code.
SHOUPCLS("3", "dtoc(cobegdate)+' '+alltrim(cocrsenm)","alltrim(cosubcode) $ 'COMPBUS'",5) returns begin date and course title of courses that have the COMP or BUS subject code that begin 5 days from today's date and occur within the next 3 months.
SHOUPCLS("3", "dtoc(cobegdate)+' '+alltrim(cocrsenm)","",0,"cocategory='SEMINAR'") returns begin date and course title of courses where the course category is "SEMINAR".
ACEweb Users Example - course title will be a link to course on ACEweb.
IMPORTANT: this example uses HTMLÂ and can only be used in an HTMLÂ formatted email templates. It also uses the ACEweb URL preference (on System Preferences) for the ACEweb domain.
SHOUPCLS("between(cobegdate,date(),date()+14)","[<p>
]+dtoc(cobegdate)+[ - <a href='\]+alltrim(xs\_awurl)+\[CourseStatus.awp?&course=\]+alltrim(cocrse)+\['>\]+alltrim(cocrsenm)+\[</a></p>
]","",0,"(comax-coenrolled)=>1") returns begin date and course title of courses that begin in the next 14 days, with course title a link to the course in ACEweb.
Notes ​
The above examples use the standard FoxPro functions: BETWEEN and DATE
This function will automatically exclude inactive courses.