<%@ LANGUAGE="VBSCRIPT" %> Manage Web Subscriptions <% Server.ScriptTimeout = 9999 on error resume next ' localizable strings L_strDocCre_TEXT = "Document Created" L_strDocMod_TEXT = "Document Modified" L_strDocDel_TEXT = "Document Deleted" L_strDocMov_TEXT = "Document Moved" L_strDocAll_TEXT = "All Document Changes" L_strCmtAdd_TEXT = "Comment Added" L_strCmtDel_TEXT = "Comment Deleted" L_strCmtAll_TEXT = "All Comment Changes" L_strAll_TEXT = "All Changes" L_strInv_TEXT = "Invalid" L_ConfirmStr_TEXT = "Are you sure you want to delete all Web Subscriptions currently showing?" L_FilterError_TEXT = "You must enter a value, or select All Web Subscriptions." L_DelErrorStr_TEXT = "An error occured when deleting the selected Web Subscription." L_SubDeletedStr_TEXT = "The selected Web Subscription has been deleted." L_ConnErrorStr_TEXT = "An error occurred when retrieving your selection. Possible causes are that the connection to the server is down or you do not have permission to do this operation. Try again, or if this error persists, check the status of your Office database." L_AccessErrorStr_TEXT = "You do not have access to the selected subscription. Only the subscription owner or an administrator is allowed to delete a subscription." L_NoSubsStr_TEXT = "There are no Web Subscriptions on this server" L_AllDelStr_TEXT = "All Web Subscriptions matching your criteria have been deleted" L_NoFilterStr_TEXT = "There are no Web Subscriptions which match your criteria" L_Head1_TEXT = "User" L_Head2_TEXT = "URL" L_Head3_TEXT = "Subscribed To" L_Head4_TEXT = "Email Address" L_IE3ErrStr_TEXT = "This page uses a Java applet that does not work on Internet Explorer 3.0. Please upgrade to 4.0 or higher to use this page." ' Declare Constants dim OWS_EVT_DOCCREATE,OWS_EVT_DOCMODIFY,OWS_EVT_DOCDELETE,OWS_EVT_DOCMOVE,OWS_EVT_DOCALL dim OWS_EVT_CMTADD,OWS_EVT_CMTDEL,OWS_EVT_CMTALL,OWS_EVT_ALL,OWSEVTCOL_EVTID dim FILTER_NONE,FILTER_OWNER,FILTER_URL,FILTER_MAIL dim E_SELECTIONFAILED, E_ACCESSDENIED OWS_EVT_DOCCREATE = 0 OWS_EVT_DOCMODIFY = 1 OWS_EVT_DOCDELETE = 2 OWS_EVT_DOCMOVE = 3 OWS_EVT_DOCALL = 4 OWS_EVT_CMTADD = 5 OWS_EVT_CMTDEL = 6 OWS_EVT_CMTALL = 7 OWS_EVT_ALL = 8 OWSEVTCOL_EVTID = 5 E_SELECTIONFAILED = 90001 E_ACCESSDENIED = 70 ' This is VB's error message for permission denied. FILTER_NONE = 0 FILTER_OWNER = 1 FILTER_URL = 2 FILTER_EMAIL = 3 ' Declare Variables dim SubCnt,FiltCol,evtid,Subscriptions,Subsc,FilteredSubs,tgtsub,outstr dim leftstr,rightstr,strpos,UserStr dim iRet dim useragent ' HTTP_USER_AGENT string from browser dim ieverstr ' MSIE Version string from HTTP_USER_AGENT dim iever ' IE Version (integer for comparison) ' get browser version useragent = Request.ServerVariables("HTTP_USER_AGENT") ieverstr = Mid(useragent,Instr(useragent,"MSIE")+5,4) iever = Left(ieverstr,1) if IsNumeric(iever) = False then iever = 0 if Instr(useragent,"MSIE") <> 0 and iever < 4 then %>

<%=L_IE3ErrStr_TEXT%>

<% else iRet = 0 if Session("fMiscApis") <> True then Set Session("MiscApis") = Server.CreateObject("OWS.MiscApis.1") Session("fMiscApis") = True End If if Request.Form("rdChoice") <> "" then Session("rdChoice") = Request.Form("rdChoice") if Session("rdChoice") <> "all" then Session("filtertype") = Request.Form("filtertype") UserStr = Request.Form("txtUser") if CInt(Request.Form("filtertype")) = FILTER_URL then if (StrComp(Left(UserStr,4),"http") <> 0 and StrComp(Left(UserStr,4),"file") <> 0) then Session("txtUser") = "http://" & UserStr else Session("txtUser") = UserStr end if else Session("txtUser") = UserStr end if else Session("filtertype") = FILTER_NONE Session("txtUser") = "" end if end if if Session("rdChoice") = "all" then FiltCol = 0 elseif CInt(Session("filtertype")) = FILTER_OWNER then FiltCol = 3 elseif CInt(Session("filtertype")) = FILTER_URL then FiltCol = 1 elseif CInt(Session("filtertype")) = FILTER_EMAIL then FiltCol = 4 end if if Request.Form("delForm") = "TRUE" then evtid = Request.Form("evtid") if evtid = "ALL" then Set Subscriptions = Session("MiscApis").EnumEvtSubs(Session("txtUser"),FiltCol,3,0) if Err.Number <> 0 then iRet = E_SELECTIONFAILED Err.Clear else Do While Subscriptions.EOF <> True Set Subsc = Subscriptions.Item() Subscriptions.Delete(Subsc.EventID) if Err.Number <> 0 then iRet = Err.Number Err.Clear Exit Do end if Subscriptions.Next Loop if iRet = 0 then %><% end if end if else Set Subscriptions = Session("MiscApis").EnumEvtSubs(evtid,OWSEVTCOL_EVTID,0,0) if Err.Number <> 0 then iRet = E_SELECTIONFAILED Err.Clear else if Subscriptions.EOF = False then set tgtsub = Subscriptions.Item() if tgtsub.EventID = evtid then Subscriptions.Delete(tgtsub.EventID) ' Check for error E_ACCESSDENIED if Err.Number <> 0 then iRet = Err.Number Err.Clear else %><% end if end if end if end if end if end if Set FilteredSubs = Session("MiscApis").EnumEvtSubs(Session("txtUser"),FiltCol,3,0) if Err.Number <> 0 then iRet = E_SELECTIONFAILED Err.Clear end if %> Administration Home Get Help on this page

Manage Web Subscriptions


The list below shows the Web Subscriptions created on this Office-extended server. Click a column heading to sort by that field. You can delete any Web Subscription. To display a subset of the Web Subscriptions, select Web Subscriptions Where, choose a field from the dropdown list, type the value you want to match, and click Update. The value of a Web Subscription must match the value you type exactly in order for it to be displayed. To return to displaying all Web Subscriptions, select All Web Subscriptions and hit Update.
" name="filtform">
Show: "filter" then%> checked <%end if%>> All Web Subscriptons
checked <%end if%>> Web Subscriptions Where: = 0 then response.write Session("txtUser")%>" onFocus="this.form.rdChoice[1].checked = 1;">
Updated: <%=Date & " " & Time%>
<% if CInt(Session("filtertype")) = FILTER_NONE then %> <% elseif DelAll = True then %> <% else %> <% end if%> "> "> <% SubCnt = 0 if IsEmpty(FilteredSubs) = False then Do While FilteredSubs.EOF = False Set Subsc = FilteredSubs.Item() select case Subsc.EventType case OWS_EVT_DOCCREATE szEvtType = L_strDocCre_TEXT case OWS_EVT_DOCMODIFY szEvtType = L_strDocMod_TEXT case OWS_EVT_DOCDELETE szEvtType = L_strDocDel_TEXT case OWS_EVT_DOCMOVE szEvtType = L_strDocMov_TEXT case OWS_EVT_DOCALL szEvtType = L_strDocAll_TEXT case OWS_EVT_CMTADD szEvtType = L_strCmtAdd_TEXT case OWS_EVT_CMTDEL szEvtType = L_strCmtDel_TEXT case OWS_EVT_CMTALL szEvtType = L_strCmtAll_TEXT case OWS_EVT_ALL szEvtType = L_strAll_TEXT case else szEvtType = L_strInv_TEXT end select urlStr = Subsc.ScopeURL ' Flip backlashes Do While (Instr(urlStr,"\") <> 0) strpos = Instr(urlStr,"\") leftstr = Left(urlStr,strpos-1) rightstr = Right(urlStr,len(urlStr)-strpos) urlStr = leftstr & "/" & rightstr Loop %> <% SubCnt = SubCnt + 1 FilteredSubs.Next Loop end if %>
Connected to: <%=Request.ServerVariables("SERVER_NAME")%>
Displaying <%=SubCnt%> Web Subscription(s)
" name=delForm>
<% end if %>