The ASPError Object has zero (0) Methods, nine (9) Properties, zero (0) Events, and zero (0) Collections.
AspCode
AspDescription
Category
Column
Description
File
Line
Number
Source
The way you access the ASPError Properties is with a Server Method. Yeah, I know; it doesn't make sense. Start with something like
Below is the script for Lesson 15.
<%@LANGUAGE="JavaScript"%> <!-- METADATA TYPE="typelib" FILE="C:\Program Files\Common Files\System\ado\msado15.dll" --> <% try { Response.Write("<STRONG>Use <I>GetLastError( )</I><BR></STRONG>\r") myError = Server.GetLastError() Response.Write("myError.Line: " + myError.Line + "<BR>\r") Response.Write("myError.File: " + myError.File + "\r") Response.Write("<HR>\r<STRONG>") Response.Write("Now an intentional error...") Response.Write("<BR></STRONG>\r") myError = erver.GetLastError() //this line causes an error Response.Write("myError.Line: " + myError.Line + "<BR>\r") Response.Write("myError.File: " + myError.File + "<BR>\r") } catch(myDumbError) { Response.Write("There is an error: " + myDumbError) %> <BR> Graceful error handling goes here (inside the catch statement). Make it as simple or sophisticated as you like.<BR> <HR> <STRONG>Now let's break down the error Object.</STRONG><BR> <% for ( var i in myDumbError) { Response.Write(i + ": " + myDumbError[i] + "<BR>\r") } } finally { Response.Write("<HR><STRONG>Let's Finish Up.</STRONG><BR>\r") Response.Write("Code inside the <I>finally { }</I> statement ") Response.Write("executes regardless of error (or lack thereof). \r") Response.Write("<I>finally{ }</I> is totally optional. ") Response.Write("It's a good place for things like RS.Close()... ") Response.Write("which you'll see later on.") } %>
Click Here to run the script in a new window.
Okay, so what happened to On Error Resume Next? Sorry, that ain't no JavaScript thing. So, what about onerror? That won't work on the server side. But thanks to some core JavaScript we have some error handling.
The section of script for which you wish to provide error handling goes inside the try { } statements and the what-to-do in the event of an error goes inside the catch { } statement. There is also a finally { } statement (optional). The whole thing is just as graceful as On Error (in my opinion).
Not every ASP server allows you access to the ASPError Object. So, don't be surprised if ASPError gives you an error.
免责声明:本站资源来自互联网收集,仅供用于学习和交流,请遵循相关法律法规,本站一切资源不代表本站立场,如有侵权、后门、不妥请联系本站删除!
RTX 5090要首发 性能要翻倍!三星展示GDDR7显存
三星在GTC上展示了专为下一代游戏GPU设计的GDDR7内存。
首次推出的GDDR7内存模块密度为16GB,每个模块容量为2GB。其速度预设为32 Gbps(PAM3),但也可以降至28 Gbps,以提高产量和初始阶段的整体性能和成本效益。
据三星表示,GDDR7内存的能效将提高20%,同时工作电压仅为1.1V,低于标准的1.2V。通过采用更新的封装材料和优化的电路设计,使得在高速运行时的发热量降低,GDDR7的热阻比GDDR6降低了70%。
更新日志
- 群星1998《宝丽金最精彩98》香港首版[WAV+CUE][1G]
- 汪峰《也许我可以无视死亡》星文[WAV+CUE][1G]
- 李嘉-1991《国语转调2》[天王唱片][WAV整轨]
- 蔡琴2008《金声回忆录101》6CD[环星唱片][WAV整轨]
- 群星《2024好听新歌36》AI调整音效【WAV分轨】
- 梁朝伟.1986-朦胧夜雨裡(华星40经典)【华星】【WAV+CUE】
- 方芳.1996-得意洋洋【中唱】【WAV+CUE】
- 辛欣.2001-放120个心【上海音像】【WAV+CUE】
- 柏菲·万山红《花开原野1》限量开盘母带ORMCD[低速原抓WAV+CUE]
- 柏菲·万山红《花开原野2》限量开盘母带ORMCD[低速原抓WAV+CUE]
- 潘安邦《思念精选集全纪录》5CD[WAV+CUE]
- 杨千嬅《千嬅新唱金牌金曲》金牌娱乐 [WAV+CUE][985M]
- 杨钰莹《依然情深》首版[WAV+CUE][1G]
- 第五街的士高《印度激情版》3CD [WAV+CUE][2.4G]
- 三国志8重制版哪个武将智力高 三国志8重制版智力武将排行一览