Search This Blog


How to place both VB and CS File in App_Code directory

The single App_Code directory can only contain files of the same language.

However, you can add subdirectories to the App_Code directory
in order to process multiple languages under the App_Code directory.

In order to do this, you need to register each subdirectory in the application's Web.config.

<compilation debug="false">
<add directoryName="VBFiles"/>
<add directoryName="CSFiles"/>

Then, simply creating the App_Code\VBFiles and App_Code\CSFiles directories,
and placing your VB and CS files in each, will allow you to use both languages in your app.

No comments: