Thursday, July 30, 2009

Is it possible to add an ASP.NET page coded with VB in a ASP.NET with C# project ?

Simply i have a ASP.NET with C# project. And i want to add a page for online payment written in VB .. is that possible ?

Is it possible to add an ASP.NET page coded with VB in a ASP.NET with C# project ?
If you are creating ASP.Net pages with different server code languages like VB/C# then there is no problem...


To share App_Code folder for VB and C# classes then you can learn it here...


http://programming.top54u.com/post/Code-...
Reply:Yes it is possible if you are using VS 2005 with ASP.NET 2.0. From you solution explorer, Right Click the folder where you want to add the page, and select add new item.





Hope this helps.
Reply:Yes, in Visual Studio 2005 (.net 2.0) or greater





The trick is to make sure you have the vb.net file in a separate directory and change your web.config file





This goes in the compilation section


%26lt;codeSubDirectories%26gt;


%26lt;add directoryName="subdir1" /%26gt;


%26lt;add directoryName="etc..." /%26gt;


%26lt;/codeSubDirectories%26gt;


No comments:

Post a Comment