MVC :: Could Not Load Type While Running VS2010 Project
May 23, 2010
I have had a project called Articles and the project complies fine. I have it running as a seperate site on my machine and it works like a charm under IIS7. When I start the project from VS2010 in debug mode (by pressing F5) it lands on a page that says: "Parser Error Message: Could not load type 'Articles._Default'."
I i however change the path in the browser from [URL] Home it works fine again, indicating that my routing table is bust but it was working yesterday and I did not change any route, The error page also says: "Please do not delete this file. It is used to ensure that ASP.NET MVC is activated by IIS when a user makes a "/" request to the server." That idicates to me that it went to default.aspx...right?
View 3 Replies
Similar Messages:
Apr 23, 2010
So bit the bullet and installed vs2010 finally. However, when loading an existing vs2008 project, I am getting this error: "The project type is not supported by this installation." the only thing special about this project is that it's a "web application projects" type. what I've tried so far are these steps, but none of these solve my problem:
(1) run "devenv /setup"
(2) regsvr32.exe "%ProgramFiles%Microsoft Visual Studio 10.0Common7IDEProjectAggregator.dll"
View 1 Replies
Jun 10, 2010
We are using nested master page the master page is seperate class library project and all the other projects refer to them. We wanted to have a basepage class which load title, meta tags and keywords dynamically. It was working fine till it was inside the main project. We wanted the basepage class to be more generic and to have it reside in a single place. So i tried created a seperate class library project but i getting error "Could not load type" ..
How to have the basepage class outside the project?
View 3 Replies
Mar 17, 2010
I have an ASP.NET 3.5 website application using C# and SQL 2005 running on a web server. Now the application has the ability to create new aspx pages with content and the relative aspx.cs and design.cs pages needed on the fly and store them in the base directory on the server. Think of it as a crued Visual Studio website on the server for admin to click a few options on a page then the new pages are created for them without the need of a web developer. This all works fine and the code is working 100% (for the moment).
My problem now is the following: When i now navigate to this newly created page i get the following error - Parse Error : Could not load type 'Namespace.PageName'
I've looked into the reasoning and microsoft say "These errors occur if the .aspx page contains a reference to a code-behind module and if the application has not been built." Which now makes sense the application does not realise that these new pages are part of its system even though i can navigate to them.How do i get the system to recognise these new pages and rebuild itself accordingly?Now i cannot rebuild the system localy then reupload to the server, this needs to be accomplished on the server by the system, because the site cannot afford to have down time everytime admin decide to add new pages.
View 3 Replies
Jun 2, 2010
I have a MasterPage project which is a class library project (it includes themes, style sheets, menus etc) and all applications use them.
I am using the BasePage concept for dynamically adding title,meta tags and descriptions. This BasePage Class inherits system.UI.Page and the aspx pages in the project inherits the BasePage class.
Now i need to move this BasePage class from my application to the Master Page Project so that all the projects/applications can reuse the same code.
I tried add the basepage.cs in the App_code folder and tried calling it in the page directive like below
<%@
Page
Language="C#"
MasterPageFile="~/Master/Layout/MasterPage.master"
AutoEventWireup="true"
CodeBehind="xxxx.aspx.cs"
CodeFile="xxxx.aspx.cs"
Inherits="xxxx"
ValidateRequest="false"
EnableEventValidation="false"
ViewStateEncryptionMode="Never"
CodeFileBaseClass="~/Master/App_Code/BasePage<Page>"
Title="Title"
Meta_Keywords="xxxx,yyyy,zzzz"
Meta_Description="This is a test" %>
But i am getting error
Could not load type '~/Master/App_Code/BasePage<Page>'.
This was working fine till the BasePage class was inside the application. But once i moved it out of the project and added it to the master page project i getting this error.
View 3 Replies
Jan 5, 2011
I would like to include a word document, and unused program files in a folder as part of my project, but I don't want it compiled, etc. How is the best way to do this?
View 1 Replies
Jun 20, 2010
I've created a new vs.net project and added all the files from an asp.net website project.
When I compile, it couldn't find a reference to a class.
In the AppCode the class was defined, but without a namespace.
So I added a namespace, and then on the default.aspx.cs (this is where the error was originating) I added the using statement.
The using statement was not picking up the namespace.
View 3 Replies
Jan 7, 2011
I have several ASP.NET web projects and their Output folder are set to "C:Builds[ProjectName]bin" (instead of the default "bin" folder). This makes "F5" Debugging not working because the ASP.NET Development Server expects the "bin" folder under the project folder.
I then changed to use Local IIS Web server (http://localhost/webproject1") and manually updated the vdir physical path to my custom output path. However the VS2010 will not load the csproj because it detects the url is already mapped to a different folder location.
I know I probably shouldn't change the Output folder. But wondering if there is an easy way to workaround this? The goal is to make "F5" debugging work with custom build Output folders.
View 2 Replies
Mar 8, 2011
I'm about to begin a new asp.net application using .net 4.0. Only concern I have is since the project calls for reporting, I cannot use SSRS with SQL Server 2008 b/c the tempate for Bus Intelligence Projects is missing from 4.0. I've been told that the next release of SQL Server 2011 (some time this year), will resolve this problem. Meanwhile, I'm wondering if the following approach would work:
1) Create the application in VS2010 using the SQL Server 2008 db.
2) Create the SSRS Bus Intelligence project using VS2008 and create a seperate website pointing to the same SQL Server 2008 Db?
Kind of a hack, but I guess the only problem with this is, the Bus Intelligence project will not be able to reference and leverage and DLL or code from the application.
View 1 Replies
Mar 31, 2011
I'm trying to publish my mvc3 project to a web host server, I right clicked my project and selected publish, there i entered the ftp information, VS2010 uploaded the files to the ftp, but when i try to surf to the remote site i get an error "Directory Listing Denied". all guides I found requierd an installation on the web host side, is there no way to just upload the site like in classic asp?
View 2 Replies
May 1, 2010
I'm a bit cautions about converting one of my sites to .net 4 at the same instant I move to vs2010. When I convert the sln and csproj files, there is an option to "convert web sites to .net 4" which I did not check.Once I get more comfortable using vs2010, I'd like to do that conversion to .net 4, but I can't find an option to do that in VS.
View 2 Replies
Feb 21, 2011
I'm working on a "Website Project" (as opposed to an ASP.NET Web Application) which we received from another company as part of an acquisition.In general it works fine, however every time I close the project ("File" -> "Close Project" or just "File" -> "Exit"), the IDE crashes.If I create a new project this doesn't happen, and it doesn't happen for any other project/solution file I have handy.The other information I have that might be useful is that this project may have stared out as a VS2008 project, and previously it was under Microsoft source control (it's under Subversion now).
View 3 Replies
Mar 23, 2010
I get the following error which I don't get when I build a simple WCF Data Service in an non MVC project. I added the following to my global.asax:
[Code]....
The type 'MvcWebApp.WcfDataServiceTwitter', provided as the Service attribute value in the ServiceHost directive, or provided in the configuration element system.serviceModel/serviceHostingEnvironment/serviceActivations could not be found.
View 2 Replies
Jan 26, 2010
is it possible to make a single assembly for whole WebSite in Visual Studio 2010?
With Web Deployment Project i can do this in VS2008, but it is not compatible with new version.
View 1 Replies
Jun 6, 2010
I just upgraded from VS2008 to VS2010, and now my web deployment project keeps rebuilding constantly. Even if I have a WinForms application set as the startup project and hit Ctrl+F5 to run it, the web deployment project rebuilds every time I hit Ctrl+F5. It didn't do this in VS2008. Does anyone know what's causing this?
View 1 Replies
Jun 8, 2010
I am getting the following error when I try to build an ASP.NET 4 project in Visual Studio 2010: "Could not load file or assembly 'file:///C:Devproject runkinElmah.dll' or one of its dependencies. Operation is not supported. (Exception from HRESULT: 0x80131515)". I have verified that the dll does, in fact, exist, and is getting copied to the bin folder correctly. I have also tried removing and then re-adding the reference to the project.
The build only fails when I switch the Solution Configuration to "Release". It does not fail when the Solution Configuration is set to "Debug". The only difference between the two configurations (that I know of) is shown in the following Web.config transform, Web.Release.config:
<?xml version="1.0"?>
<configuration xmlns:xdt="[URL]">
<connectionStrings>
<add name="SqlServer" connectionString="" providerName="System.Data.SqlClient" xdt:Transform="SetAttributes" xdt:Locator="Match(name)"/>
</connectionStrings>
<system.web>
<compilation xdt:Transform="RemoveAttributes(debug)" />
<customErrors mode="On" xdt:Transform="Replace">
<error statusCode="404" redirect="lost.htm" />
<error statusCode="500" redirect="uhoh.htm" />
</customErrors>
</system.web>
</configuration>
I have tried using Fusion Log Viewer to track down the assembly binding issue, but it looks like it is finding and loading the assembly correctly. Here is the log:
*** Assembly Binder Log Entry (6/8/2010 @ 10:01:54 AM) ***
The operation was successful.
Bind result: hr = 0x0. The operation completed successfully.
Assembly manager loaded from: C:WindowsMicrosoft.NETFrameworkv4.0.30319clr.dll
Running under executable c:Program Files (x86)Microsoft SDKsWindowsv7.0AinNETFX 4.0 Toolssgen.exe
A detailed error log follows.
Pre-bind state information ===
LOG: User = User
LOG: Where-ref bind. Location = C:Devproject runkinElmah.dll
LOG: Appbase = file:///c:/Program Files (x86)/Microsoft SDKs/Windows/v7.0A/bin/NETFX 4.0 Tools/
LOG: Initial PrivatePath = NULL
LOG: Dynamic Base = NULL
LOG: Cache Base = NULL
LOG: AppName = sgen.exe
Calling assembly : (Unknown).
LOG: This bind starts in LoadFrom load context.
WRN: Native image will not be probed in LoadFrom context. Native image will only be probed in default load context, like with Assembly.Load().
LOG: No application configuration file found.
LOG: Using host configuration file:
LOG: Using machine configuration file from C:WindowsMicrosoft.NETFrameworkv4.0.30319configmachine.config.
LOG: Attempting download of new URL file:///C:/Dev/project/trunk/bin/Elmah.dll.
LOG: Assembly download was successful. Attempting setup of file: C:Devproject runkinElmah.dll
LOG: Entering run-from-source setup phase.
LOG: Assembly Name is: Elmah, Version=1.1.11517.0, Culture=neutral, PublicKeyToken=null
LOG: Re-apply policy for where-ref bind.
LOG: Where-ref bind Codebase does not match what is found in default context. Keep the result in LoadFrom context.
LOG: Binding succeeds. Returns assembly from C:Devproject runkinElmah.dll.
LOG: Assembly is loaded in LoadFrom load context.
View 2 Replies
Nov 3, 2010
I have been working on this project for a few months in VS2008.. now that we are getting closer to the end, one of the other programmers has been working and doing his in VS2010, so when i try to open his projects in VS2008 it just shows up as XML.. so i have to open in VS2010.. thats fine..
But if i try to open my project in 2010, it prompts to use the conversion wizard.. Should i be concerned or are there any issues with doing the conversion? Being the end of the project, i dont want to cause issues at this point.. So would like to know if converting the project file at this stage in our project a good idea? Will there be any issues using his code with mine since they were developed in 2 different versions..
View 1 Replies
Nov 4, 2010
How do I upgrade an existing VS2010 ASP.Net 3.5 project from Entity Framework 3.5 to Entity Framework 4.0?
Do I:
- Change the references?
- Change the target framework?
View 2 Replies
Mar 20, 2010
I created an MVC project in vs2010 RC and i cant really tell if its running on MVC 2 Beta or the freshly released MVC Release. Is there anything i can look out for to determine this?
View 12 Replies
Sep 6, 2010
I have a VS2010 Web Application that uses the AjaxControlToolkit. I am able to build the Debug configuration. When I build the release configuration I get the following error message: Error 89 Could not load file or assembly 'file:///S:My CodeLibrariesACTMay 2010AjaxControlToolkit.dll' or one of its dependencies. Operation is not supported. (Exception from HRESULT: 0x80131515) S:My CodeEZFishingEZFishingEZFishingSGEN EZFishing
The location of the file is correct, and I just downloaded and unzipped there the Ajax CT. I have always built this app correctly before upgrading to VS2010 and ACT May 2010.
View 3 Replies
Nov 19, 2010
This could be a simple one but it has got me baffled. I have a ASP.NET solution that I have stored in C/inetpub/www/root/website. The solution and project files are all stored in there and I have set it up as a virtual directory in IIS.so I can view the web page in 2 ways.
1. - By running the solution [URL]
2. - By viewing the url in IE: [URL]
I changed the project to use windows authentication and I added alabel in the top right of the page which displays the user logged in i.e. DOMAINusername.
When I run the solution from VS2008 it displays the username on the page no problem (that is my logon id since I am running it). But when I view the page by typing the URL into IE - it doesnt seem to recognise the authentication and it doesnt display my DOMAINusername in the label.
Any ideas why this is? I thought maybe it was something to do with the .dlls but I did a simple test. In the project I created a new a label on the page and in the page_load I wrote "label.text = "Test Text". In both cases the label showed "Test Text" as expected so it is nothing to do with building the solution. Is there something about windows authentication - why would it work in one case and not in the other? So as a third test I actually opened IIS and right-clicked on the my website in the console and choose "browse".
I then got the following error:
Sequence contains no elements
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.InvalidOperationException: Sequence contains no elements
Source Error:
[Code]....
Now I set a break point at this point in my project in VS2008 - but when I run it there it doesnt even go to this code!
View 3 Replies
Feb 3, 2010
when i tried to run my old project then i am getting this error:
Could not load file or assembly 'System.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified.C:UsersGautamDocumentsVisual Studio 2005WebSitesOnlineShoppingProjectWeb.Config33
View 13 Replies
Dec 17, 2010
I use Mac as my primary OS, but I often work on ASP.NET MVC projects. I want to use the same file system for them, and not virtual OS image.
The reason for that is because I want to integrate the projects with Mac OS (i.e. upload them to the server via Transmit, a Mac OS FTP app).
But the problem here is that ASP.NET can't really work with projects located on network drives. So when I try to run a site (either with VS 2010's built in web server or with IIS 7), I get
Error Summary HTTP Error 500.19 - Internal Server Error The requested page cannot be accessed because the related configuration data for the page is invalid.
And this is a common mistake but no solution that I could find worked for me.
If I create a project on Parallel's virtual C: drive, everything works fine.
P.S. I hear that VMWare has better network drives support, but is it as smooth as Parallels? Parallels 6 runs extremely fast for me, and my Mac Mini doesn't even get warm with VS 2010 and several other Mac apps open.
P.P.S. I also heard about using DropBox and/or Windows Live Mesh. Is clouding a good idea in this case?
View 1 Replies
Feb 16, 2011
when i run my project i got bellow error...
"Validation of viewstate MAC failed. If this application is hosted by a Web Farm or cluster, ensure that <machineKey> configuration specifies the same validationKey and validation algorithm. AutoGenerate cannot be used in a cluster."
View 1 Replies
Feb 25, 2011
I'm attempting to run/debug an ASP.NET MVC project under .NET 4.0 using VS2010's Dev Web Server. The server appears to spawn successfully and an instance of IE Explorer opens. However, the browser never seems to find the page. The browser just "spins" showing only a white page...no error message.VS is configured to randomly select a port, although I get the same results when configuring numerous static ports.The ASP.NET project is the start-up project.
View 2 Replies