简体   繁体   English

将 WebService 从 vs2008 转换为 vs2010

[英]Converting WebService from vs2008 to vs2010

So I converted a webservice from VS2008 to VS2010.所以我将一个 Web 服务从 VS2008 转换为 VS2010。

when I run it in the debugger, instead of opening the page where I can choose a web method, like in 2008, the browser asks me if I want to open the aspx file in visual studio当我在调试器中运行它时,而不是打开可以选择 web 方法的页面,就像在 2008 年一样,浏览器询问我是否要在 Visual Studio 中打开 aspx 文件

I'm sure this must have been encountered by somone before in the past.我敢肯定,这在过去一定是有人遇到过的。 But my googling skills failed me...但是我的谷歌搜索技能让我失望了......

Anyone know how to fix this so it behaves as I expect from working in vs2008?任何人都知道如何解决这个问题,所以它的行为与我在 vs2008 中工作时所期望的一样吗?

Thanks,谢谢,

Cal-卡尔-

Okay I figured it out.好吧,我想通了。

I created a new webservice in the project by following the steps here:我按照此处的步骤在项目中创建了一个新的 Web 服务:

http://forums.asp.net/t/1597083.aspx/1 http://forums.asp.net/t/1597083.aspx/1

It ran as expected.它按预期运行。

So I changed the old web service from 4.0 back to 3.5, then changed it back again to 4.0.所以我把旧的 web 服务从 4.0 改回 3.5,然后又改回 4.0。

Ran the project and everything worked.运行项目,一切正常。

For what its' worth, when I upgraded the project, I let VS2010 change it ot 4.0 automatically, perhaps this was the mistake.为了它的价值,当我升级项目时,我让VS2010自动将其更改为4.0,也许这是错误的。 If I do it agian soon, I'll leave it 3.5 then manually change it to 4.0 that's worked for other webapps (though not tested on a service)如果我很快再做,我会把它保留为 3.5,然后手动将其更改为适用于其他 webapps 的 4.0(尽管未在服务上测试)

Thanks,谢谢,

Cal-卡尔-

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM