Mixed Language Development with WAP

A

AG

Thanks to help from this group I was able to use both VB and C# in a Website
Project, so I understand about creating language subfolders under App_Code
folder.

However, I have another project that I converted from Website Project to Web
Application Project.
It is all VB except for one C# class.
Since there is no App_Code folder with WAP, is there any way to still
include the C# class in the same project or am I resigned to either
converting it to VB or making it a separate project and referencing it in
the WAP?

TIA
 
J

Juan T. Llibre

re:
!> Since there is no App_Code folder with WAP, is there
!> any way to still include the C# class in the same project

See Rick Strahl's blog entry on this :

"WAP recognizes the special APP_CODE folder but requires
that it be renamed and so it creates a OLD_APP_CODE folder.

It creates the folder containing files marked with a Build Action - Content
(select the source code file and look at properties). The file should be
marked with Build Action – Compile.

Without this none of your APP_CODE related code will be
recognized most likely causing big problems for compilation."
 
W

Walter Wang [MSFT]

Hi AG,

The WAP compiles your code into a single assembly, therefore I don't think
it's possible to use mixed language in it. You can create a separate C#
class library and put the C# class there, then reference the class from
your web project.

Hope this helps.


Regards,
Walter Wang ([email protected], remove 'online.')
Microsoft Online Community Support

==================================================
When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
==================================================

This posting is provided "AS IS" with no warranties, and confers no rights.
 
A

AG

That's what I thought, but just wanted to confirm.
One more question. Is there any performance difference in a site published
via the Website model vs WAP?
 
A

AG

Thanks for the quick reply, Juan.

I could not find his blog entry, but did find his white paper. It does
provide a link
http://webproject.scottgu.com/CSharp/Migration2/Migration2.aspx for
instructions to convert from Website to WAP. It happens to be the same
instructions I had used to do my conversion.
My site is already converted and works. I just had to put the C# class into
a separate class library and was wondering if there was another way to mix
languages.
 
W

Walter Wang [MSFT]

I don't think there're any notable performance difference.


Regards,
Walter Wang ([email protected], remove 'online.')
Microsoft Online Community Support

==================================================
When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
==================================================

This posting is provided "AS IS" with no warranties, and confers no rights.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,997
Messages
2,570,240
Members
46,830
Latest member
HeleneMull

Latest Threads

Top