<%@ Language=VBScript%> <% Response.Buffer = True %> <% 'Local Variables to be used in the page.. Dim ComID, bInit, bExecuted, fExecuted, pExecuted, message 'Initialize the Page for each server request InitializePage() %> <% '~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Function InitializePage() bInit = CBool(Request.Querystring ("init")) If Request.Form("selComm") = "0" AND Not bInit Then message = "You must select a committe to view description." 'Response.Clear Response.Redirect "error.asp?mess=" + Server.URLEncode(message) Response.End End If If bInit <> Cint(False) then ComId = Cint(0) else ComId = Cint(Request.Form("selComm")) End IF End Function '~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ '~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Function GetMember(rsMember)%> <% On Error Resume Next GetMember = False Dim StrSQL StrSQL = " SELECT [FACULTY].[F_NAME], [FACULTY].[L_NAME], [MEMBER].[TERM], [DIVISION].[DIVISION] FROM [FACULTY], [MEMBER], [COMM1], [DIVISION] " StrSQL = StrSQL + "WHERE [COMM1].[COMID] = [MEMBER].[COMID] AND [FACULTY].[USER_ID] = [MEMBER].[USER_ID] AND " StrSQL = StrSQL + " [DIVISION].[DIV_ID] = [FACULTY].[DIV_ID] AND [COMM1].[COMID] = " + Cstr (ComID) StrSQL = StrSQL + " ORDER BY [MEMBER].[TERM]" dbNVS.Open rsMember.ActiveConnection = dbNVS rsMember.Open Cstr(StrSQL), dbNVS, adOpenKeyset ', adLockOptimistic If Not rsMember.EOF Then rsMember.Movefirst End If GetMember = True If Err.Number <> 0 Then GetMember = False End If End Function '~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ '~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Function GetProfile(rsProfile)%> <% On Error Resume Next GetProfile = False Dim StrSQL StrSQL = "SELECT * FROM [COMM1]" StrSQL = StrSQL + " WHERE [COMID]= " + Cstr(ComId) dbNVS.Open rsProfile.ActiveConnection = dbNVS rsProfile.Open Cstr(StrSQL), dbNVS, adOpenKeyset ', adLockOptimistic If Not rsProfile.EOF Then rsProfile.Movefirst End If GetProfile = True If Err.Number <> 0 Then GetProfile = False End If End Function '~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ %> <% Set rsComm = Server.CreateObject("ADODB.Recordset") GetCommittees rsComm %> Nomination and Voting System - Committee Description <%Title = "Committee Profile" %> <% IF rsComm.EOF then %>


There are no committees
<% Else %>
<% End IF %> <% dbNVS.Close If Not bInit then Set rsMember = Server.CreateObject("ADODB.Recordset") GetMember rsMember %> <%If rsMember.EOF then %> <%Else%> <%'display members Do while NOT rsMember.EOF %> <% rsMember.MoveNext Loop%> <%End If %>
Committee Members   Term   Division  
Currently no committee members
<%=rsMember.fields("F_Name").value + " " + rsMember.fields("L_Name").value%>   <%=rsMember.fields("TERM").value%>   <%=rsMember.fields("DIVISION").value%>  
<% dbNVS.Close Set rsProfile = Server.CreateObject("ADODB.Recordset") GetProfile rsProfile %>
<%If IsNull(rsProfile.fields("COMDESC").value) Then%> <%Else%>
<%End If %>
Committee Description
There is no description for this committee
<%=rsProfile.fields("COMDESC").value%>
<%If IsNull(rsProfile.fields("MEMDESC").value) Then%> <%Else%>
<%End If %>
Membership Description
There is no description for this committee
<%=rsProfile.fields("MEMDESC").value%>
<% dbNVS.close Set dbNVS = Nothing Set rsMember = Nothing Set rsProfile = Nothing Set rsComm = Nothing %> <%End If Response.End%>