Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

823 lines
20 KiB

  1. <!--#INCLUDE file="..\include\asp\top.asp"-->
  2. <!--#INCLUDE file="..\include\inc\browserTest.inc"-->
  3. <!--#include file="..\include\asp\head.asp"-->
  4. <!--#INCLUDE file="..\include\inc\locatestrings.inc"-->
  5. <%
  6. Dim strPreviousPage
  7. Dim strCookies
  8. Dim strEmail
  9. Dim strPhone
  10. Dim strName
  11. Dim cmComments
  12. Dim cnConnection
  13. if Trim(Request.Cookies("Misc")("PreviousPage")) <> "customer.asp" and Trim(Request.Cookies("Misc")("PreviousPage")) <> "locate.asp" and Trim(Request.Cookies("Misc")("PreviousPage")) <> "view.asp" and Trim(Request.Cookies("Misc")("PreviousPage")) <> "received.asp" and Trim(Request.Cookies("Misc")("PreviousPage")) <> "submit.asp" then
  14. Response.Redirect("http://" & Request.ServerVariables("SERVER_NAME") & "/welcome.asp")
  15. Response.End
  16. end if
  17. strPreviousPage = Request.ServerVariables("SCRIPT_NAME")
  18. strPreviousPage = Right(strPreviousPage, len(strPreviousPage) - Instrrev(strPreviousPage, "/"))
  19. Response.Cookies("Misc")("PreviousPage") = strPreviousPage
  20. If oPassMgrObj.IsAuthenticated(TimeWindow, ForceLogin) = false then
  21. Response.Redirect("http://" & Request.ServerVariables("SERVER_NAME") & "/welcome.asp")
  22. Response.End
  23. end if
  24. Response.Buffer = true
  25. if Request.Cookies("Misc")("unassoc") = "true" then
  26. Response.Cookies("Misc")("txtIncidentID") = "~|~|"
  27. end if
  28. Response.Cookies("Misc")("unassoc") = "false"
  29. Call CCreateObjects
  30. Call CCreateConnection
  31. Call CSetCustomer
  32. Call CDestroyObjects
  33. Private Sub CSetCustomer
  34. on error resume next
  35. strName = unescape(Request.Cookies("Customer")("txtCustomerName"))
  36. strPhone = unescape(Request.Cookies("Customer")("txtCustomerPhone"))
  37. strEmail = unescape(Request.Cookies("Customer")("txtCustomerEmail"))
  38. if Len(strName)=4 and strName="~|~|" then
  39. strName = ""
  40. end if
  41. if Len(strPhone)=4 and strPhone="~|~|" then
  42. strPhone = ""
  43. end if
  44. if Len(strEmail)=4 and strEmail="~|~|" then
  45. strEmail = ""
  46. end if
  47. with cmComments
  48. .ActiveConnection = cnConnection
  49. .CommandText = "SetCustomer"
  50. .CommandType = adCmdStoredProc
  51. .CommandTimeout = strGlobalCommandTimeout
  52. .Parameters.Append .CreateParameter("@HighID", adInteger, adParamInput, , clng(oPassMgrObj.Profile("MemberIdHigh")))
  53. .Parameters.Append .CreateParameter("@LowID", adInteger, adParamInput, , clng(oPassMgrObj.Profile("MemberIdLow")))
  54. .Parameters.Append .CreateParameter("@EMail", adVarWChar, adParamInput, 128, trim(left(strEmail, 128)))
  55. .Parameters.Append .CreateParameter("@Contact", adVarWChar, adParamInput, 32, trim(left(strName, 32)))
  56. .Parameters.Append .CreateParameter("@Phone", adVarWChar, adParamInput, 16, trim(left(strPhone, 16)))
  57. .Parameters.Append .CreateParameter("@PremierID", adVarWChar, adParamInput, 16, cstr(Request.Cookies("intCustomerPremierID")))
  58. .Parameters.Append .CreateParameter("@Lang", adVarWChar, adParamInput, 4, strAbb)
  59. .Execute
  60. end with'Verify no errors
  61. if cnConnection.Errors.Count > 0 then
  62. Response.Write "<br><div class='divLoad'><p class='clsPTitle'>" & L_COMMENTS_UNABLE_TOCONNECT_ERRORMESSAGE & "</p>"
  63. Response.Write "<p class='clsPBody'>" & L_COMMENTS_DATABASE_FAILED_TEXT & "</p></div>"
  64. cnConnection.Errors.Clear
  65. Call CDestroyObjects
  66. end if
  67. End Sub
  68. Private Sub CCreateConnection
  69. on error resume next
  70. 'Open the connection to the database the constant is located in the dataconnections.inc
  71. with cnConnection
  72. .ConnectionString = strCustomer
  73. .CursorLocation = adUseClient
  74. .ConnectionTimeout = strGlobalConnectionTimeout
  75. .Open
  76. end with
  77. 'If unable to conect with the database then display message
  78. if cnConnection.State = adStateClosed then
  79. Response.Write "<br><div class='divLoad'><p class='clsPTitle'>" & L_COMMENTS_UNABLE_TOCONNECT_ERRORMESSAGE & "</p>"
  80. Response.Write "<p class='clsPBody'>" & L_COMMENTS_CONNECTION_FAILED_TEXT & "</p></div>"
  81. Response.Write "<p class='clsPBody'>Error Number:" & cnConnection.Errors(0).Number & "</p>"
  82. Response.Write "<p class='clsPBody'>Error Description:" & cnConnection.Errors(0).Description & "</p></div>"
  83. cnConnection.Errors.Clear
  84. Call CDestroyObjects
  85. %>
  86. <!--#include file="..\include\asp\foot.asp"-->
  87. <%
  88. Response.End
  89. end if
  90. End Sub
  91. Private Sub CCreateObjects
  92. on error resume next
  93. set cnConnection = CreateObject("ADODB.Connection")
  94. set cmComments = CreateObject("ADODB.Command")
  95. End Sub
  96. Private Sub CDestroyObjects
  97. on error resume next
  98. 'Close connection object and set ado objects to nothing
  99. if cnConnection.State = adStateOpen then cnConnection.Close
  100. set cmComments = nothing
  101. set cnConnection = nothing
  102. End Sub
  103. 'Session.LCID = strLCID
  104. %>
  105. <OBJECT id="win2kdmp" name="win2kdmp" UNSELECTABLE="on" style="display:none"
  106. CLASSID="clsid:D68DAEED-C2A6-4C6F-9365-4676B173D8EF"
  107. codebase="https://<%=Request.ServerVariables("SERVER_NAME")%>/secure/OCARPT.CAB#version=<%= strGlobalVersion %>" height="0" Vspace="0">
  108. <BR>
  109. <div class="clsDiv">
  110. <P class="clsPTitle">
  111. <% = L_LOCATE_WARN_ING_ERRORMESSAGE %>
  112. </P>
  113. <p class="clsPBody">
  114. <% = L_FAQ_WHYDOIGETAMESSAGEBOX_DETAILSONE_TEXT %><BR>
  115. <% = L_FAQ_WHYDOIGETAMESSAGEBOX_DETAILSTWO_TEXT %><BR>
  116. <% = L_FAQ_WHYDOIGETAMESSAGEBOX_DETAILSTHREE_TEXT %><BR><BR>
  117. <% = L_FAQ_WHYDOIGETAMESSAGEBOX_DETAILSFOUR_TEXT %><BR>
  118. <% = L_FAQ_WHYDOIGETAMESSAGEBOX_DETAILSFIVE_TEXT %><BR>
  119. <% = L_FAQ_WHYDOIGETAMESSAGEBOX_DETAILSSIX_TEXT %><BR>
  120. </p>
  121. </div>
  122. </OBJECT>
  123. <div id="divLoad" name="divLoad" class="divLoad">
  124. <P class="clsPTitle"><% = L_LOCATE_DUMP_FILES_MESSAGE%></p>
  125. <p class="clsPBody">
  126. <% = L_LOCATE_DUMP_FILESBODY_MESSAGE%>
  127. </p>
  128. </div>
  129. <div id="divMain" name="divMain" class="clsDiv" style="visibility:hidden">
  130. <p class="clsPTitle">
  131. <% = L_LOCATE_EVENT_REPORTS_TEXT%>
  132. </P>
  133. <p class="clsPBody">
  134. <% = L_LOCATE_EVENT_DETAILS_TEXT%>
  135. </p>
  136. <p id="pResults" name="pResults" class="clsPSubTitle">
  137. <% = L_LOCATE_SEARCH_RESULTS_TEXT%>
  138. </P>
  139. <p class="clsPBody">
  140. <Table name="tblMain" id="tblMain" bgcolor="Silver" class="clsTableInfo" border=1 CELLPADDING="0px" CELLSPACING="0px">
  141. <thead>
  142. <tr>
  143. <td nowrap class="clsTDInfo" width="5%">
  144. &nbsp;
  145. </td>
  146. <td id="Head2" name="Head2" nowrap class="clsTDInfo" width="20%">
  147. <Label for=Head2>
  148. &nbsp;<% = L_LOCATE_EVENT_DATE_TEXT%>&nbsp;&nbsp;
  149. </Label>
  150. </td>
  151. <td id="Head3" name="Head3" nowrap class="clsTDInfo" width="55%">
  152. <Label for=Head3>
  153. &nbsp;<% = L_LOCATE_FILE_PATH_TEXT%>&nbsp;&nbsp;
  154. </Label>
  155. </td>
  156. <td id="Head4" name="Head4" nowrap class="clsTDInfo" width="20%">
  157. <Label for=Head4>
  158. &nbsp;<% = L_LOCATE_SUB_MITTED_TEXT%>&nbsp;&nbsp;
  159. </Label>
  160. </td>
  161. </tr>
  162. </thead>
  163. <tbody name="tblBody" id="tblBody" >
  164. </tbody>
  165. </table>
  166. <Table class="clsTableNormal" border=0>
  167. <tbody>
  168. <tr>
  169. <td nowrap>
  170. <Input type="radio" id="optFile" onclick="browseclick();"name="optFile">
  171. </td>
  172. <td nowrap colspan="2" width="75%">
  173. <Input type="text" class="clsTextTD" onkeyup="txtBrowse_keydown();"id="txtBrowse" name="txtBrowse" >
  174. </td>
  175. <td nowrap align="right">
  176. <Input type="button" class="clsButtonNormal" value="<% = L_LOCATE_BROWSE_BUTTONTEXT_TEXT %>..." onclick="cmdBrowse_onclick();" name="cmdBrowse" id="cmdBrowse">
  177. </td>
  178. </tr>
  179. </tbody>
  180. </table>
  181. </p>
  182. <P class="clsPBody">
  183. <Table class="clstblLinks">
  184. <thead>
  185. <tr>
  186. <td>
  187. </td>
  188. <td>
  189. </td>
  190. <td>
  191. </td>
  192. <td>
  193. </td>
  194. </tr>
  195. </thead>
  196. <tbody>
  197. <tr>
  198. <td nowrap class="clsTDLinks">
  199. <A class="clsALink" href="http://<% =Request.ServerVariables("SERVER_NAME") %>/welcome.asp" ><% = L_LOCATE_CANCEL_LINK_TEXT%></a>
  200. </td>
  201. <td nowrap class="clsTDLinks">
  202. <A class="clsALink" href="JAVASCRIPT:customer_onclick();"><% = L_LOCATE_PREVIOUS_LINK_TEXT%></a>
  203. </td>
  204. <td nowrap class="clsTDLinks">
  205. <A class="clsALink" href="JAVASCRIPT:view_onclick();"><% = L_SUBMIT_VIEW_CONTENTS_TEXT %></a>
  206. </td>
  207. <td nowrap class="clsTDLinks">
  208. <A id="submitlink" name="submitlink" class="clsALink" href="JAVASCRIPT:submitlink_onclick();"><% = L_CUSTOMER_NEXT_LINK_TEXT %></a>
  209. </td>
  210. </tr>
  211. </tbody>
  212. </table>
  213. </p>
  214. </div>
  215. <br><br><br>
  216. <Input name="txtLanguage" id="txtLanguage" type="hidden" value="<%=strAbb%>">
  217. <Input name="txtCookies" id="txtCookies" type="hidden" value="<%=strCookies%>">
  218. <script language="javascript">
  219. <!--
  220. var strFiles = new String();
  221. var strType = new String();
  222. var strArr;
  223. var bolIsEncrypted;
  224. var strTempName;
  225. var strFileName;
  226. var strTempFileName;
  227. document.body.onload = BodyLoad;
  228. function LoadData(intAttribute)
  229. {
  230. var Attribute;
  231. spnUserData.load("OCADataStore");
  232. switch(intAttribute)
  233. {
  234. case 0:
  235. {
  236. if(spnUserData.getAttribute("FileOption") != null && spnUserData.getAttribute("FileOption") != "")
  237. {
  238. Attribute = spnUserData.getAttribute("FileOption");
  239. return Attribute;
  240. }
  241. else
  242. {
  243. return 0;
  244. }
  245. }
  246. break;
  247. case 1:
  248. {
  249. if(spnUserData.getAttribute("Browse") != null && spnUserData.getAttribute("Browse") != "")
  250. {
  251. Attribute = spnUserData.getAttribute("Browse");
  252. return Attribute;
  253. }
  254. else
  255. {
  256. return "";
  257. }
  258. }
  259. }
  260. }
  261. function LoadFileData()
  262. {
  263. var Attribute;
  264. spnUserData.load("OCADataStore");
  265. Attribute = spnUserData.getAttribute("UploadedFiles");
  266. return Attribute;
  267. }
  268. function SaveData(intAttribute, strData)
  269. {
  270. var oTimeNow = new Date(); // Start Time
  271. var sExpirationDate;
  272. switch(intAttribute)
  273. {
  274. case 0:
  275. spnUserData.setAttribute("FileOption", strData);
  276. break;
  277. case 1:
  278. spnUserData.setAttribute("Browse", strData);
  279. break;
  280. }
  281. oTimeNow.setYear(oTimeNow.getYear() + 2);
  282. sExpirationDate = oTimeNow.toUTCString();
  283. spnUserData.expires = sExpirationDate;
  284. spnUserData.save("OCADataStore");
  285. }
  286. function validate_file()
  287. {
  288. if(strFileName=="undefined")
  289. {
  290. alert("<% = L_LOCATE_SELECT_FILE_MESSAGE %>");
  291. return false;
  292. }
  293. //bolIsEncrypted = GetCookie("intCustomerPremierID");
  294. //if(bolIsEncrypted==0 || bolIsEncrypted=="" || bolIsEncrypted==null)
  295. //{
  296. //bolIsEncrypted = 0;
  297. //}
  298. //else
  299. //{
  300. bolIsEncrypted = 1;
  301. //}
  302. strTempName = strFileName[0];
  303. sRes = -1;
  304. var bolValidate = win2kdmp.validatedump(bolIsEncrypted, strFileName[0]);
  305. if(bolValidate != 0)
  306. {
  307. switch(bolValidate)
  308. {
  309. case 1:
  310. alert("<% = L_SUBMIT_FILE_INVALID_ERRORMESSAGE %>");
  311. return false;
  312. break;
  313. case 2:
  314. alert("<% = L_SUBMIT_CONVERSION_FAILED_ERRORMESSAGE %>");
  315. return false;
  316. break;
  317. case 3:
  318. alert("<% = L_SUBMIT_ONLYPRIMIER_CUSTOMERS_ERRORMESSAGE %>");
  319. return false;
  320. break;
  321. /*case 4:
  322. if(confirm("<% = L_LOCATE_64BIT_UPLOAD_MESSAGE %>") == false)
  323. {
  324. return false;
  325. }
  326. break;*/
  327. case 5:
  328. alert("<% = L_SUBMIT_CONVERSION_FAILED_ERRORMESSAGE %>");
  329. return false;
  330. break;
  331. }
  332. }
  333. return true;
  334. }
  335. function save_filename(oDirection)
  336. {
  337. var x;
  338. var hr;
  339. var sFileName;
  340. strFileName = "";
  341. try
  342. {
  343. if(optFile(optFile.length-1).checked)
  344. {
  345. if(txtBrowse.value == "")
  346. {
  347. if(oDirection == 1)
  348. {
  349. alert("<% = L_LOCATE_SELECT_FILE_MESSAGE %>");
  350. }
  351. return false;
  352. }
  353. sFileName = txtBrowse.value;
  354. x = optFile.length - 1;
  355. document.cookie = "optFile=" + x;
  356. SaveData(0, optFile.length-1);
  357. }
  358. else
  359. {
  360. for(x=0;x<(optFile.length);x++)
  361. { //
  362. if(optFile[x].checked == true)
  363. {
  364. document.cookie = "optFile=" + x;
  365. SaveData(0, x);
  366. if((optFile.length) == x)
  367. {
  368. if(txtBrowse.value == "")
  369. {
  370. if(oDirection == 1)
  371. {
  372. alert("<% = L_LOCATE_SELECT_FILE_MESSAGE %>");
  373. }
  374. return false;
  375. }
  376. sFileName = txtBrowse.value;
  377. }
  378. else
  379. {
  380. sFileName = strArr[x];
  381. }
  382. }
  383. }
  384. }
  385. }
  386. catch(e)
  387. {
  388. if(txtBrowse.value == "")
  389. {
  390. if(oDirection == 1)
  391. {
  392. alert("<% = L_LOCATE_SELECT_FILE_MESSAGE %>");
  393. }
  394. return false;
  395. }
  396. sFileName = txtBrowse.value;
  397. }
  398. strTempFileName = sFileName;
  399. document.cookie = "ocaFileName = " + escape(sFileName);
  400. SaveData(1, txtBrowse.value);
  401. strFileName = strTempFileName.split(",");
  402. return true;
  403. }
  404. function txtBrowse_keydown()
  405. {
  406. var strTemp;
  407. strTemp = txtBrowse.value;
  408. if(strTemp.length > 0)
  409. {
  410. try
  411. {
  412. optFile[optFile.length-1].checked = true;
  413. }
  414. catch(e)
  415. {
  416. optFile.checked = true;
  417. }
  418. }
  419. }
  420. function browseclick()
  421. {
  422. cmdBrowse.focus();
  423. }
  424. function view_onclick()
  425. {
  426. if(save_filename(1)==false)
  427. {
  428. return;
  429. }
  430. if(validate_file() == false)
  431. {
  432. return;
  433. }
  434. var strHash = win2kdmp.gethash(strFileName[0]);
  435. if(strHash == "")
  436. {
  437. for(x=0;x<5;x++)
  438. {
  439. strHash = win2kdmp.gethash(strFileName[0]);
  440. if(strHash != "")
  441. {
  442. x = 5;
  443. }
  444. }
  445. if (strHash == "")
  446. {
  447. alert("<% = L_LOCATE_HASH_INFO_MESSAGE %>");
  448. return;
  449. }
  450. }
  451. document.cookie = "strHash = " + strHash;
  452. window.navigate("view.asp");
  453. return;
  454. }
  455. function customer_onclick()
  456. {
  457. save_filename(0);
  458. window.navigate("customer.asp");
  459. }
  460. function submitlink_onclick()
  461. {
  462. var sRes;
  463. if(save_filename(1)==false)
  464. {
  465. return;
  466. }
  467. if(validate_file() == false)
  468. {
  469. return;
  470. }
  471. var strHash = win2kdmp.gethash(strFileName[0]);
  472. if(strHash == "")
  473. {
  474. for(x=0;x<5;x++)
  475. {
  476. strHash = win2kdmp.gethash(strFileName[0]);
  477. if(strHash != "")
  478. {
  479. x = 5;
  480. }
  481. }
  482. if (strHash == "")
  483. {
  484. alert("<% = L_LOCATE_HASH_INFO_MESSAGE %>");
  485. return;
  486. }
  487. }
  488. document.cookie = "strHash = " + strHash;
  489. window.navigate("submit.asp");
  490. return;
  491. }
  492. function BodyLoad()
  493. {
  494. divMain.style.visibility = "hidden";
  495. try
  496. {
  497. if(win2kdmp)
  498. {
  499. var strFileList = new String();
  500. var strTemp;
  501. var iPos;
  502. var iLen;
  503. var oRow;
  504. var oCell;
  505. var strCookies = new String();
  506. var x;
  507. var y;
  508. var bolResults;
  509. var strDate = new Date();
  510. var strBrowse;
  511. var oDate = new Date();
  512. var strDate;
  513. var strLoadFileData;
  514. var strSearch;
  515. var strTempCookies;
  516. var oTimeExpiresNow = new Date();
  517. var strUnderline = new String();
  518. divLoad.innerHTML = "<P class='clsPSubTitle'><% = L_LOCATE_DUMP_FILES_MESSAGE%></p>";
  519. strFileList = "";
  520. strFileList = win2kdmp.Search();
  521. strLoadFileData = LoadFileData();
  522. if(strFileList.length > 0)
  523. {
  524. iPos = strFileList.search(":");
  525. strFiles = strFileList.slice(iPos + 1, strFileList.length);
  526. strType = strFileList.slice(0, iPos);
  527. strArr = strFiles.split(";");
  528. iLen = strArr.length;
  529. iLen--;
  530. if(strLoadFileData!="" && strLoadFileData != null)
  531. {
  532. strTemp = strLoadFileData;
  533. strCookies = strTemp.split(",");
  534. }
  535. for(x=0;x<iLen;x++)
  536. {
  537. strTemp = strArr[x].split(",");
  538. oRow = tblBody.insertRow();
  539. oCell = oRow.insertCell();
  540. oCell.bgColor = "#FFFFFF";
  541. oCell.innerHTML = "<Input type='radio' id='optFile' name='optFile'>";
  542. oCell = oRow.insertCell();
  543. oCell.bgColor = "#FFFFFF";
  544. oCell.noWrap = true;
  545. if(strTemp[1] != "")
  546. { //Date
  547. try
  548. {
  549. oDate = new Date(strTemp[1]);
  550. strDate = oDate;
  551. delete(oDate);
  552. }
  553. catch(e)
  554. {
  555. strDate = strTemp[1];
  556. }
  557. oCell.name = "tdACell" + x;
  558. oCell.id = "tdACell" + x;
  559. oCell.innerHTML = "&nbsp;<Label for=tdACell" + x + ">" + strTemp[1] + "</Label>&nbsp;&nbsp;";
  560. }
  561. else
  562. {
  563. oCell.innerHTML = "&nbsp;";
  564. }
  565. oCell = oRow.insertCell();
  566. oCell.bgColor = "#FFFFFF";
  567. oCell.noWrap = true;
  568. oCell.name = "tdBCell" + x;
  569. oCell.id = "tdBCell" + x;
  570. //oRow.insertAdjacentHTML("afterBegin", </Label>");
  571. if(strTemp[0] != "")
  572. {
  573. //oCell.innerText = strTemp[0];
  574. oCell.insertAdjacentHTML("afterBegin", "&nbsp;" + "<Label for=tdBCell" + x + ">" + strTemp[0]);
  575. oCell.insertAdjacentHTML("beforeEnd", "</Label>&nbsp;&nbsp;");
  576. oCell.style.wordBreak = "break-all";
  577. }
  578. else
  579. {
  580. oCell.innerHTML = "&nbsp;";
  581. }
  582. oCell = oRow.insertCell();
  583. oCell.bgColor = "#FFFFFF";
  584. oCell.name = "tdCCell" + x;
  585. oCell.id = "tdCCell" + x;
  586. if(strLoadFileData != "")
  587. {
  588. bolResults = false;
  589. for(y=0;y < strCookies.length-1;y++)
  590. {
  591. strSearch = new String(strTemp[0]);
  592. strTempCookies = new String(strCookies[y]);
  593. strUnderline = new String(strCookies[y]);
  594. strUnderline = strUnderline.replace("_", "-");
  595. strSearch = strSearch.split("\\");
  596. if(strTempCookies.charAt(0)== " ")
  597. {
  598. strTempCookies = strTempCookies.substr(1, strTempCookies.length);
  599. }
  600. if(strTempCookies==strSearch[strSearch.length-1])
  601. {
  602. bolResults = true;
  603. strDate = strCookies[y+1];
  604. }
  605. if(strUnderline==strSearch[strSearch.length-1])
  606. {
  607. bolResults = true;
  608. strDate = strCookies[y+1];
  609. }
  610. delete(strTempCookies);
  611. delete(strSearch);
  612. }
  613. if(bolResults==true)
  614. {
  615. try
  616. {
  617. strDate = strDate.toLocaleString();
  618. oCell.innerHTML = "&nbsp;" + "<Label for=tdCCell" + x + ">" + strDate.toLocaleString() + "</Label>&nbsp;&nbsp;";
  619. }
  620. catch(e)
  621. {
  622. oCell.innerHTML = "&nbsp;";
  623. }
  624. }
  625. else
  626. {
  627. oCell.innerHTML = "&nbsp;";
  628. }
  629. }
  630. else
  631. {
  632. oCell.innerHTML = "&nbsp;";
  633. }
  634. }
  635. if(LoadData(0) != "")
  636. {
  637. optFile[LoadData(0)].checked = true;
  638. }
  639. else
  640. {
  641. try
  642. {
  643. optFile[0].checked = true;
  644. }
  645. catch(e)
  646. {
  647. optFile.checked = true;
  648. }
  649. }
  650. }
  651. else
  652. {
  653. oRow = tblBody.insertRow();
  654. oCell = oRow.insertCell();
  655. oCell.bgColor = "#FFFFFF";
  656. oCell.colSpan = 4;
  657. oCell.align = "center";
  658. oCell.innerHTML = "<% = L_LOCATE_NO_FILESFOUND_TEXT%>";
  659. optFile.checked = true;
  660. }
  661. divLoad.innerHTML = " ";
  662. divMain.style.visibility = "visible";
  663. }
  664. }
  665. catch(e)
  666. {
  667. }
  668. strBrowse = GetCookie("ocaFileName");
  669. if(strBrowse==null)
  670. {
  671. strBrowse = "";
  672. }
  673. try
  674. {
  675. if(optFile[optFile.length-1].checked==true)
  676. {
  677. txtBrowse.value = strBrowse;
  678. }
  679. }
  680. catch(e)
  681. {
  682. if(optFile.checked==true)
  683. {
  684. txtBrowse.value = strBrowse;
  685. }
  686. }
  687. divLoad.style.visibility = "hidden";
  688. divLoad.style.display = "none";
  689. tblMain.style.backgroundColor = "#6487DC";
  690. try
  691. {
  692. if(win2kdmp)
  693. {
  694. divMain.style.visibility = "visible";
  695. if(GetCookie("optFile") != null)
  696. {
  697. optFile[GetCookie("optFile")].checked = true;
  698. }
  699. }
  700. }
  701. catch(e)
  702. {
  703. }
  704. return;
  705. }
  706. function cmdBrowse_onclick()
  707. {
  708. var strTemp = new String();
  709. var strNewFile = new String();
  710. var x;
  711. var iLen;
  712. var strWindowsTitle;
  713. var strLang;
  714. strLang = txtLanguage.value;
  715. strWindowsTitle = window.document.title;
  716. strTemp = win2kdmp.Browse(strWindowsTitle, strLang);
  717. if(strTemp.length > 0)
  718. {
  719. txtBrowse.value = strTemp;
  720. try
  721. {
  722. optFile(optFile.length-1).checked = true;
  723. }
  724. catch(e)
  725. {
  726. optFile.checked = true;
  727. }
  728. }
  729. }
  730. function GetCookie(sName)
  731. {
  732. var aCookie = document.cookie.split("; ");
  733. for (var i=0; i < aCookie.length; i++)
  734. {
  735. var aCrumb = aCookie[i].split("=");
  736. if (sName == aCrumb[0])
  737. return unescape(aCrumb[1]);
  738. }
  739. return null;
  740. }
  741. function DisplayCookies()
  742. {
  743. // cookies are separated by semicolons
  744. var aCookie = document.cookie.split("; ");
  745. var aCrumb = "";
  746. for (var i=0; i < aCookie.length; i++)
  747. {
  748. aCrumb = aCrumb + aCookie[i] + "\r";
  749. }
  750. alert(aCrumb);
  751. }
  752. //-->
  753. </script>
  754. <!--#include file="..\include\asp\foot.asp"-->