What assemblies does RouteConfig and BundleConfig need?

Rod At Work 866 Reputation points

'm improving on an old ASP.NET WebForms app that was assigned to me when I joined DOH back in 2015. I had to pull this thing together from bits and pieces scattered around the network, since the original developer didn't put it into any source control, didn't leave it as a Visual Studio solution, etc. Anyway, I've finally got it into TFS properly, so that it can now be tracked. Only thing now is several odd errors I'm getting when trying to build it. At the moment I'm looking at the Global.asax.vb file (the original developer coded it using VB.NET). Here's the contents of that file:

Imports System.Web.Optimization

Public Class Global_asax
    Inherits HttpApplication

    Sub Application_Start(sender As Object, e As EventArgs)
        ' Fires when the application is started
    End Sub
End Class

Visual Studio is complaining about RouteConfig and BundleConfig, saying they're not defined. I believe the issue is it's not including the necessary .NET assemblies. Its including System.Web.Optimization, but I'm wondering what else it needs?

The guy who wrote this thing (I never met him) I think wrote it using .NET 2. Maybe older. I've upgraded it to .NET 4.5.2

A set of technologies in the .NET Framework for building web applications and XML web services.
3,411 questions
{count} votes

2 answers

Sort by: Most helpful
  1. Yijing Sun-MSFT 7,071 Reputation points

    Hi @Rod At Work ,
    As far as I think,your problem is that you need to create the RouteConfig.cs and BundleConfig .cs file. These are the visual studio designed by default. You could create a new project to compare your project.

    Best regards,
    Yijing Sun

    If the answer is helpful, please click "Accept Answer" and upvote it.

    Note: Please follow the steps in our  documentation  to enable e-mail notifications if you want to receive the related email notification for this thread.

    0 comments No comments