ASP.NET中VB和C#的类文件 [英] Class fileof VB and C# in asp.net

查看:72
本文介绍了ASP.NET中VB和C#的类文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,

我有一个Web应用程序,并有一个vb和c#页面.
现在,我已经获取了2个类文件,一个是abc.cs,另一个是xyz.vb.

现在事情是这样的,当我在vb页面中调用vb类时,它的生成错误.
编译错误.

请让我知道如何使用Classes在Web应用程序中使用两种不同的语言进行操作

谢谢你
mohd Wasif

解决方案

您需要创建App_Code文件夹,然后在其下面有一个VB和C#文件夹.自然地,您将VB类保留在VB文件夹中,并将C#类保留在C#文件夹中.所有人都应该与世界接轨. [ ^ ] .

这几乎是第一个答案中提到的内容-但是,它为您提供了需要执行的步骤.


Hi All,

I have a web application and having a vb and c# page .
Now I have taken 2 class file one abc.cs and second xyz.vb.

Now the thing is this when i am calling vb class in vb page its generation error.
compilation error.

Please let me know how to work in two different languages in a web application using Classes

thanking you
mohd Wasif

解决方案

You need to create the App_Code folder and then have a VB and C# folder beneath that. Naturally, you keep VB classes in the VB folder and C# classes in the C# folder. All should then be good with the world.


See here[^].

This is pretty much what has been mentioned in the first answer - however, it gives you the steps to what you need to do.


这篇关于ASP.NET中VB和C#的类文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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