ASP.Net入门 [英] Getting Started in ASP.Net

查看:64
本文介绍了ASP.Net入门的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用VB2005编写了我的第一个asp.net程序。它有一个带有

Hello World的文本框。当我从IDE运行它时,它就出现了。然后我做了一个

发布网络到我的本地IIS文件夹并运行default.aspx文件它

想出了以下内容:

XML解析错误:格式不正确

位置:file:/// C:/Inetpub/wwwroot/WebViewer/Default.aspx

行号1,第2列:<%@ page language =" VB" ; autoeventwireup =" false"

inherits =" _Default,App_Web_u2trtlt1" %>


有什么不对吗?


-Jerry

I''ve written my first asp.net program using VB2005. It has a textbox with
"Hello World". When I run it from the IDE, it comes up OK. I then did a
"publish web" to my local IIS folder and ran the default.aspx file and it
came up with the following:

XML Parsing Error: not well-formed
Location: file:///C:/Inetpub/wwwroot/WebViewer/Default.aspx
Line Number 1, Column 2:<%@ page language="VB" autoeventwireup="false"
inherits="_Default, App_Web_u2trtlt1" %>

What is wrong please?

-Jerry

推荐答案

2月21日上午9:30,Jerry Spence1 < jerry.spe ... @ somewhere.com>

写道:
On Feb 21, 9:30 am, "Jerry Spence1" <jerry.spe...@somewhere.com>
wrote:

我写了我的第一个asp.net程序使用VB2005。它有一个带有

Hello World的文本框。当我从IDE运行它时,它就出现了。然后我做了一个

发布网络到我的本地IIS文件夹并运行default.aspx文件它

想出了以下内容:

XML解析错误:格式不正确

位置:file:/// C:/Inetpub/wwwroot/WebViewer/Default.aspx

行号1,第2列:<%@ page language =" VB" ; autoeventwireup =" false"

inherits =" _Default,App_Web_u2trtlt1" %>


有什么问题?
I''ve written my first asp.net program using VB2005. It has a textbox with
"Hello World". When I run it from the IDE, it comes up OK. I then did a
"publish web" to my local IIS folder and ran the default.aspx file and it
came up with the following:

XML Parsing Error: not well-formed
Location: file:///C:/Inetpub/wwwroot/WebViewer/Default.aspx
Line Number 1, Column 2:<%@ page language="VB" autoeventwireup="false"
inherits="_Default, App_Web_u2trtlt1" %>

What is wrong please?



听起来你的应用程序没有为IIS中的ASP.NET配置,

因为它看到的是.ASPX文件作为XML文件而不是.net

页面。

Sounds like your application isn''t configured for ASP.NET in IIS,
because it''s seeing the .ASPX file as an XML file instead of a .net
page.




" Larry Bud" ; < la ********** @ yahoo.comwrote in message

news:11 ******************** **@p10g2000cwp.googlegr oups.com ...

"Larry Bud" <la**********@yahoo.comwrote in message
news:11**********************@p10g2000cwp.googlegr oups.com...

2月21日上午9:30,Jerry Spence1 < jerry.spe ... @ somewhere.com>

写道:
On Feb 21, 9:30 am, "Jerry Spence1" <jerry.spe...@somewhere.com>
wrote:

>我写了第一个asp。使用VB2005的网络程序。它有一个带有
Hello World的文本框。当我从IDE运行它时,它就出现了。然后我做了一个
发布网络。到我的本地IIS文件夹并运行default.aspx文件,它提出了以下内容:

XML解析错误:格式不正确
位置:file:// /C:/Inetpub/wwwroot/WebViewer/Default.aspx
第1行,第2列:<%@ page language =" VB" autoeventwireup =" false"
inherits =" _Default,App_Web_u2trtlt1" %>

请问有什么问题?
>I''ve written my first asp.net program using VB2005. It has a textbox with
"Hello World". When I run it from the IDE, it comes up OK. I then did a
"publish web" to my local IIS folder and ran the default.aspx file and it
came up with the following:

XML Parsing Error: not well-formed
Location: file:///C:/Inetpub/wwwroot/WebViewer/Default.aspx
Line Number 1, Column 2:<%@ page language="VB" autoeventwireup="false"
inherits="_Default, App_Web_u2trtlt1" %>

What is wrong please?



听起来你的应用程序没有在IIS中为ASP.NET配置,

,因为它看到的是.ASPX文件作为XML文件而不是.net

页面。


Sounds like your application isn''t configured for ASP.NET in IIS,
because it''s seeing the .ASPX file as an XML file instead of a .net
page.



好​​点拉里。我已经通过了IIS配置并且它保持

提到ASP.NET所以我猜它是,但我不知道在哪里看起来是

肯定。


-Jerry

Good point Larry. I''ve gone though the IIS configuration and it keeps
mentioning ASP.NET so I guess it is, but I''m not sure where to look to be
sure.

-Jerry


好点拉里。我已经通过了IIS配置并保留了
Good point Larry. I''ve gone though the IIS configuration and it keeps

提到ASP.NET所以我猜它是,但我不知道在哪里看

肯定。
mentioning ASP.NET so I guess it is, but I''m not sure where to look to be
sure.



右键单击IIS中的项目(默认网站或

虚拟站点) - 在属性窗口中,首页目录选项卡,应该是

是应用程序名称的框和创建按钮的按钮。如果它还没有完成,则删除如果有的话。如果您有创建按钮然后

键入您的应用程序的名称并单击创建,脚本和

可执行文件和中型池似乎是典型的选项。


在文档选项卡上,检查Default.aspx是否为Default.aspx。已列出。如果不是,那么你可能没有在IIS中安装.net框架(如果你有一个ASP,那么有时会发生如果框架是在IIS之前安装的那么b $ b)。网络标签(来自

安装.net 2.0)然后你应该没问题我相信,虽然对于

..net 1.1你可能需要检查脚本映射以确认。


如果ASP.Net选项卡上的下拉列表有1.1.4322和2.0.50727,则安装了

..net 1.1和2.0,确保为刚刚创建的应用程序选择合适的框架



确定所有设置/窗口并重新启动应用程序...


有什么好处吗?


Rob

Right click on the item in IIS for your site (either Default Website or the
Virtual Site) - on the Properties window, Home Directory tab, there should
be a box for the application name and a button to "Create" it if it hasn''t
already been done, "Remove" if it has. If you have the create button then
type in a name for your application and click create, scripts and
executables and medium pooled seem to be the typical options.

On the Documents tab, check to see if "Default.aspx" is listed. If its not,
you might not have the .net framework installed in IIS (can sometimes happen
if the framework is installed BEFORE IIS), if you have an ASP.Net tab (comes
with .net 2.0 installation) then you should be ok I believe, although for
..net 1.1 you may need to check the script mappings to confirm.

If the drop down on the ASP.Net tab has 1.1.4322 and 2.0.50727 then both
..net 1.1 and 2.0 are installed, ensure you select the appropriate framework
for the application you''ve just created.

Ok all settings/windows and re launch your app...

Any good?

Rob


这篇关于ASP.Net入门的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆