本文介绍了'AS'关键字是否受支持?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述 29岁程序员,3月因学历无情被辞! 大家好, ASP支持关键字''as''?我有理由确定它是有效的 VBScript(我下载的代码示例使用它)但是当我尝试在 ASP中使用它时我得到了一个错误。它可能是版本问题吗? 预期声明结束 Dim conn As New ADODB.Connection ---- ----- ^ - 肖恩。Hi all,Is the keyword ''as'' supported in ASP? I''m reasonably sure it''s validVBScript (code examples I''ve downloaded use it) but when I try to use it inASP I get an error. Is it perhaps a version issue?Expected end of statementDim conn As New ADODB.Connection---------^--Sean.推荐答案 不。这是'VB。 VBscript如下: Dim conn SET conn = CreateObject( ADODB.Connection) - Mike BrindNope. That''s VB.VBscript is as follows:Dim connSET conn = CreateObject("ADODB.Connection")--Mike Brind 在vbscript中,只允许变体,所以不,AS [新]数据类型是不允许。 在 文档中查看有关VB和VBScript之间差异的两个主题,您可以从中下载: http://tinyurl.com/7rk6 - Microsoft MVP - ASP / ASP.NET 请回复新闻组。这个电子邮件帐户是我的垃圾邮件陷阱所以我 不经常检查它。如果您必须离线回复,请删除 NO SPAMIn vbscript, only variants are allowed, so no, the "AS [New] datatype" isnot allowed.See the two topics about the differences between VB and VBScript in thedocumentation you can download from: http://tinyurl.com/7rk6--Microsoft MVP - ASP/ASP.NETPlease reply to the newsgroup. This email account is my spam trap so Idon''t check it very often. If you must reply off-line, then remove the"NO SPAM" 但在ASP中使用Server.CreateObject而不是CreateObject。But in ASP use Server.CreateObject instead of CreateObject. 这篇关于'AS'关键字是否受支持?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持! 上岸,阿里云!