// *** Edit Operations: declare variables // set the form action variable MM_editAction = CGI.SCRIPT_NAME; If (CGI.QUERY_STRING NEQ "") { MM_editAction = MM_editAction & "?" & CGI.QUERY_STRING; } // boolean to abort record edit MM_abortEdit = false; // query string to execute MM_editQuery = ""; // *** Update Record: set variables If (IsDefined("MM_update") AND IsDefined("MM_recordId")) { MM_editdatasource = #MM_edu_DSN#; MM_editUserName = #MM_edu_USERNAME#; MM_editPassword = #MM_edu_PASSWORD#; MM_editTable = "foo_Calendar"; MM_editColumn = "CalendarEye"; MM_recordId = "" & MM_recordId & ""; MM_editRedirectUrl = "Calendar_Insert.txt"; MM_fieldsStr = "Calendar_Date|value|Calendar_Time|value|Calendar_Duration|value|Class_Size|value|Class_Size_Current|value|Calendar_Notes|value|ClassEye|value|ProgramEye|value|InstructorEye|value|OfficeEye|value|ContactEye|value|RoomEye|value|CreateLink|value"; MM_columnsStr = "Calendar_Date|',none,NULL|Calendar_Time|',none,NULL|Calendar_Duration|none,none,NULL|Class_Size|none,none,NULL|Class_Size_Current|none,none,NULL|Calendar_Notes|',none,''|ClassEye|none,none,NULL|ProgramEye|none,none,NULL|InstructorEye|none,none,NULL|OfficeEye|',none,''|ContactEye|none,none,NULL|RoomEye|none,none,NULL|CreateLink|none,1,0"; // create the MM_fields and MM_columns arrays MM_fields = ListToArray(MM_fieldsStr,"|"); MM_columns = ListToArray(MM_columnsStr,"|"); // set the form values For (i=1; i+1 LE ArrayLen(MM_fields); i=i+2) { MM_fields[i+1] = IIf(IsDefined(MM_fields[i]),"FORM." & MM_fields[i],DE("")); } // append the query string to the redirect URL If (MM_editRedirectUrl NEQ "" AND CGI.QUERY_STRING NEQ "") { If (Find("?", MM_editRedirectUrl) EQ 0) { MM_editRedirectUrl = MM_editRedirectUrl & "?" & CGI.QUERY_STRING; } Else { MM_editRedirectUrl = MM_editRedirectUrl & "&" & CGI.QUERY_STRING; } } } // *** Update Record: construct a sql update statement and execute it If (IsDefined("MM_update") AND IsDefined("MM_recordId")) { // create the update sql statement MM_editQuery = "update " & MM_editTable & " set "; For (i=1; i+1 LE ArrayLen(MM_fields); i=i+2) { FormVal = MM_fields[i+1]; MM_typesArray = ListToArray(MM_columns[i+1],","); Delim = IIf(MM_typesArray[1] NEQ "none","MM_typesArray[1]",DE("")); AltVal = IIf(MM_typesArray[2] NEQ "none","MM_typesArray[2]",DE("")); EmptyVal = IIf(MM_typesArray[3] NEQ "none","MM_typesArray[3]",DE("")); If (FormVal EQ "") { FormVal = EmptyVal; } Else { If (AltVal NEQ "") { FormVal = AltVal; } Else If (Delim EQ "'") { // escape quotes FormVal = "'" & Replace(FormVal,"'","''","ALL") & "'"; } Else { FormVal = Delim & FormVal & Delim; } } If (i GT 1) MM_editQuery = MM_editQuery & ","; MM_editQuery = MM_editQuery & MM_columns[i] & " = " & FormVal; } MM_editQuery = MM_editQuery & " where " & MM_editColumn & " = " & MM_recordId; } #PreserveSingleQuotes(MM_editQuery)# SELECT tble_Office.OfficeEye, tble_Office.City FROM tble_Office ORDER BY tble_Office.City SELECT tble_Employee.EmployeeEye, tble_Employee.StudioEye, RTRIM(tble_Employee.LastName) + ' ' + RTRIM(tble_Employee.FirstName) AS Emp_Name FROM tble_Employee ORDER BY tble_Employee.LastName; SELECT ClassEye, Classtitle FROM foo_Class ORDER BY Classtitle ASC SELECT ProgramEye, ProgramLink FROM foo_Program ORDER BY ProgramLink ASC SELECT RoomEye, RoomName FROM foo_Room ORDER BY RoomName ASC SELECT foo_Instructor.InstructorEye, foo_Instructor.FirstName, foo_Instructor.LastName FROM foo_Instructor ORDER BY LastName ASC SELECT tble_Office.OfficeEye, tble_Office.City, tble_Studio.StudioEye, tble_Studio.OfficeEye, tble_Studio.StudioName, tble_Employee.EmployeeEye, tble_Employee.StudioEye, tble_Employee.StatusEye, RTRIM(tble_Employee.LastName) + ' ' + RTRIM(tble_Employee.FirstName) AS Emp_Name FROM tble_Office, tble_Studio, tble_Employee WHERE tble_Office.OfficeEye = tble_Studio.OfficeEye AND tble_Studio.StudioEye = tble_Employee.StudioEye AND tble_Employee.StatusEye IN (1, 2) ORDER BY tble_Office.City, tble_Employee.LastName; SELECT * FROM foo_Calendar WHERE CalendarEye = #CalendarUpdate__MMColParam# SELECT tble_Office.OfficeEye, tble_Office.City FROM tble_Office WHERE tble_Office.OfficeEye = #CalendarUpdate.OfficeEye# MM_paramName = ""; // *** Go To Record and Move To Record: create strings for maintaining URL and Form parameters // create the list of parameters which should not be maintained MM_removeList = "&index="; If (MM_paramName NEQ "") MM_removeList = MM_removeList & "&" & MM_paramName & "="; MM_keepURL=""; MM_keepForm=""; MM_keepBoth=""; MM_keepNone=""; // add the existing URL parameters to the MM_keepURL string MM_params=ListToArray(CGI.QUERY_STRING,"&"); For (i=1; i LTE ArrayLen(MM_params); i=i+1) { If (FindNoCase("&" & GetToken(MM_params[i],1,"=") & "=",MM_removeList) Is 0) MM_keepURL = MM_keepURL & "&" & MM_params[i]; } // add the existing Form variables to the MM_keepForm string If (IsDefined("FORM.FieldNames")) { MM_params=ListToArray(FORM.FieldNames,","); For (i=1; i LTE ArrayLen(MM_params); i=i+1) { If (FindNoCase("&" & MM_params[i] & "=",MM_removeList) Is 0) MM_keepForm = MM_keepForm & "&" & LCase(MM_params[i]) & "=" & URLEncodedFormat(Evaluate("FORM." & MM_params[i])); } } // create the Form + URL string and remove the intial '&' from each of the strings MM_keepBoth = MM_keepURL & MM_keepForm; If (MM_keepURL NEQ "") MM_keepURL = RemoveChars(MM_keepURL,1,1); If (MM_keepForm NEQ "") MM_keepForm = RemoveChars(MM_keepForm,1,1); If (MM_keepBoth NEQ "") MM_keepBoth = RemoveChars(MM_keepBoth,1,1);
Calendar Update Admin Page :: Update Calendar Entry
If the instructor for the class is not in the instructor drop down, first add the instructor, by following the Add/Edit Instructor!
Date :
Time :
Duration : Length of class in hours. 1, 2, 3.
# of Slots: The number of students who can attend the class, after number full, signs ups will be tenative.
# of Slots Current: The number of students who have currently signed up for the class.
Notes :
Class Name : Add/Edit/Delete Class
Program : Add/Edit/Delete Program
Instructor : Add/Edit/Delete Instructor
   
Office :
Contact:
Contact will be the sender of announcement.
Room : Conatact Volker Mueller to add a room
  You need to reserve the room in outlook before you submit this form!
Create Link Now : CHECKED class='input'> Adding a check here enables the signup form.
If changes made to this form please hit Submit before sending email.
 
Send Email : Click Once to Send Office Wide Email Announcement to Office #rs_OfficeCity.City#