Visual Studio 2008 - .Net Error: "The Type 'foo' Exists In Both "temp1.dll" And "temp2.dll" (pt 2)

Apr 7, 2010

Solution,I had also moved ashx and asmx files at the same time as this. The Class attribute of the WebService/WebHandler directives were pointed at the wrong namespace. The moral of the story is to make sure you view the markup for all as*x files you change the namespace for by right-clicking on them and choosing "View Markup".

I'm experiencing the same problem as in this question and this link, but none of the answers fixed my problem. (edit: Setting the web.config batch attribute works, but that's a coverup, not a solution)

The problem I'm having is with a User Control that I moved from the root directory to a subdirectory within the same Web Application project. It used to work fine before I moved it. When I moved it it started giving me the error message.

It's saying that the class name exists in two dll files in Temporary ASP.NET Files. Sure enough, when I open Reflector, it's in two dlls.

If I rename the class and ascx file, everything works fine. No usages of the original name exist within any of the files in my entire application. When I rename the file, I opened all of the dll files in Temporary ASP.NET Files with Reflector, and no references to the original class name exists.

So where's this phantom reference coming from how can I fix this?

Edit: I literally grepped every file in my working directory for the solution and my temp directory for the old class name and deleted every file that contained it. I then renamed back to the original, broken name and I still get the error.

Server Error in '/' Application.

Compilation Error Description: An error occurred during the compilation of a resource required to service this request. Please review the following

specific error details and modify your source code appropriately.

Compiler Error ssage: CS0433: The type 'ASP.dashboard_badusercontrol_ascx exists in both 'c:Docunts and SettingsmeLocal
SettingsTempTemporary ASP.NET Files oot3c2b7e1f2e8a7620App_Web_badusercontrol.ascx.a57ad085.iljdmp1p.dll' and 'c:Docunts and SettingsmeLocal SettingsTempTemporary ASP.NET Files oot3c2b7e1f2e8a7620App_Web_bhdqaimy.dll'

Source Error:

Line 1098: Line 1099:
[System.Diagnostics.DebuggerNonUserCodeAttribute()]
Line 1100: private[code].....

Edit:Ok, so I did some more testing on what works and doesn't work.Let's say the original file name was "BadUserControl.ascx" in namespace "MyNamespace".

I moved the file to a directory called "NewDirectory" and changed the namespace to "MyNamespace.NewDirectory". There are no copies of "BadUserControl.ascx" anywhere else on my HDD. I double-checked my TFS history to ensure the ONLY difference is the addition of ".NewDirectory" to the namespace in the markup and code-behind files.

Inside of this namespace are two other user controls named "OtherUserControl" and "AnotherUserControl".

This situation fails:
I have 2 Register directives:

<%@ Register src="BadUserControl.ascx" tagname="BadUserControl" tagprefix="uc1" %>
<%@ Register src="OtherUserControl.ascx" tagname="OtherUserControl" tagprefix="uc2" %>

These situations work:
1) I keep "BadUserControl.ascx" named as is.
I have 1 Register directive on a page in the same namespace:
<%@ Register src="BadUserControl.ascx" tagname="BadUserControl" tagprefix="uc1" %>

2) I change "BadUserControl.ascx" to "GoodUserControl.ascx"
I have 2 Register directives:
<%@ Register src="GoodUserControl.ascx" tagname="GoodUserControl" tagprefix="uc1" %>
<%@ Register src="OtherUserControl.ascx" tagname="OtherUserControl" tagprefix="uc2" %>

3) 2 Register directives without BadUserControl.ascx at all:
<%@ Register src="AnotherUserControl.ascx" tagname="AnotherUserControl" tagprefix="uc1" %>
<%@ Register src="OtherUserControl.ascx" tagname="OtherUserControl" tagprefix="uc2" %>

View 8 Replies


Similar Messages:

Visual Studio :: Error CS0433 - Type Exists In Two Locations

Jan 10, 2011

I am using VS 2010 with an ASP.Net web application (FW: 3.5). When I run the app in VS, I get the following message:

c:WindowsMicrosoft.NETFrameworkv2.0.50727Temporary ASP.NET Files
oote7d09027703efd1App_Web_commandmodule.aspx.98f065d9.hwdz-ui2.0.cs(150): error CS0433: The type 'ASP.commandmodule_command_master' exists in both 'c:WindowsMicrosoft.NETFrameworkv2.0.50727Temporary
ASP.NET Files
oote7d09027703efd1App_Web_command.master.98f065d9.5f4zhfs0.dll' and 'c:WindowsMicrosoft.NETFrameworkv2.0.50727Temporary ASP.NET Files
oote7d09027703efd1App_Web_ltl_wu4_.dll'

I have deleted the temporary files/folders and as soon as I run the app, I get the same message and the files reappear. This is a show stopper and I do not know where to turn. I have searched the web, but the only thing I found was suggestion to delete the folders, which did not work.

View 3 Replies

Visual Studio 2008 - Finding Tools For Visual Studio 2008 Which Can Reformat ASPX Code

Jan 6, 2010

Is there any tool for Visual Studio 2008 which can reformat ASPX code to make it more presentable (eg insert line breaks, format the lines so they wrap when necessary, etc)?

View 5 Replies

Visual Studio :: Type Or Namespace Cannot Be Found Error - How To Rectify It

Jan 28, 2011

I started an app in VS2008. I did it as a web site. I installed VS 2010 (yay) today. I wanted to start over as a web project. I made a Master Page. I made content pages. One of my content pages has a form on it. Super simple text boxes and submit.


I added a folder called App_Code and placed my class files there by doing Add New Item and pasting the code into the new class. I have person and persons. The persons collection class references person. In the same folder, the persons class finds the person class. Up one level in a page's code behind, I am gettingthe error

The type or namespace name 'person' could not be found (are you missing a using directive or an assembly reference?)

For giggle, I move person.cs up a folder. Still cannot find the person. Persons collection class still CAN find person. My code behind cannot find it.

A little reading tells me I have to set that folder as an app folder in IIS. I am running Windows 7 ersonal... I cannot find IIS. If not there, I ask myself what they heck is my app running under?

for being such a noob. Anyone know what is going on here?

View 7 Replies

Visual Studio :: Error: Type Or Namespace Could Not Be Found In App_Web_weze

Jan 29, 2010

i suddenly started getting this error.

Error 13 The type or namespace name 'DisplayTrackingController' could not be found (are you missing a using directive or an assembly reference?) c:WINDOWSMicrosoft.NETFrameworkv2.0.50727Temporary ASP.NET Files emp773b35cbe8ac7005App_Web_wzekhp-n.0.cs 190 People

Although I have deleted this file from my project. why I am getting this error? and what is this file
App_Web_wzekhp-n.0.cs

View 1 Replies

Visual Studio :: Error The Type Or Namespace Name 'CaptureSource' Could Be Found?

Mar 4, 2010

i m developing an application in which i need to capture image via webcam and storing in db.

but i found Error the type or namespace name 'CaptureSource' could be found(are you missing a using directive assembly reference ) ,when i want to use it.i got this code and video from silverlight website

i try both visual studio 2010 and blend 3 still same error

View 1 Replies

Visual Studio :: Can't Launch New Project Or Solution Of Any Type - Error Message

Jan 7, 2010

I cannot get beyond the following error message when trying to load any new project or soultion of any type:

View 2 Replies

Visual Studio :: How To Convert Whole Visual Studio 2008 Web Site Project To Visual Studio 2010

Aug 14, 2010

is it possible to convert whole visual studio 2008 web site project to visual studio 2010 web site project

my current project references

i have a very annoying iis problem

iis server stops working until app pool is recycled

i am hoping that new visual studio (net framework 4.0) may solve this very annoying unsolveable problem

View 2 Replies

Visual Studio :: Cannot Launch Vwd 2008 Error Message

Jan 8, 2010

I had to reload vwd 2008 express and sql 2008 express on my laptop. After loading cannot launch vwd, get this error message. Can anyone please suggest a remedy "Failed to generate a user instance of SQL Server due to a failure in starting the process for the user instance. The connection will be closed."

View 1 Replies

C# - Visual Studio 2008 Web Application Keeps Throwing Error When First Run It?

Apr 14, 2010

As stated in the title my web application builds successfully, although every time I run it in debug mode I get the following .Net error:

If I hit refresh then the application gets no more errors until I next start it up again, any ideas?

Here is my global.asax file:

<%@ Application Language="C#" Inherits="MyCompany.Web.MyApp.Shell.CustomWebClientApplication" %>
<script runat="server">
void Session_End(Object Sender, EventArgs e)
{
FormsAuthentication.SignOut();
}
protected void Session_Start(Object sender, EventArgs e)
{
if (Session.IsNewSession)
{
Response.Redirect(System.Web.Configuration.WebConfigurationManager.AppSettings["HomePage"]);
}
}
protected void Application_Error(Object sender, EventArgs e)
{
System.Exception oops = Server.GetLastError();
//Injection attack error handling
if (oops.GetBaseException() is System.Web.HttpRequestValidationException)
{
Response.Redirect("ErrorPage.aspx");
}
}
</script>

View 4 Replies

Visual Studio :: Operation Could Not Be Completed - Unspecified Error In VS 2008

Dec 18, 2010

Now i'm using visual studio 2008 for my web application project development. I had more than 80 forms and more than 20 modules include with it. Today morning i working with my applicatons normally. Suddenly i cant debug my applications but when i tried to run the webform by View in Browser option, The seperate form shows the page and output. And i cant dubug or Run my Whole project manually. When i tried to debug the applications, suddenly the below error pop-up will displayed without any debuging.

The Operation Could not be completed. unspecified error

View 1 Replies

Visual Studio 2008 - How To Resolve Build Error In Asp.net Website

Jan 31, 2011

I have one text box control on aspx page in my .net application.

and in code behind on page load event i wrote:

txt.Text = "Sample"

Now if build website on system [ windows XP ] it build properly but on system [ Windows 7 Enterprise ] it showing following error:

" Name 'txt' is not declared "

What would be the reason.Is that environment specific problem.I am using VS 2008.

View 1 Replies

Visual Studio :: Opening Visual Studio 2008 Project In Visual Studio 2010?

May 21, 2010

Anyone know if I can maintain a VS 2008 (.net 3.5) project by using the VS 2010 IDE ?

View 1 Replies

Visual Studio :: Entry Point Not Found Error / Installing Vs 2008?

Jun 1, 2010

Im trying to install VS 2008 on Server 2008 R2. As I try to run the Setup.exe file I get this Error:

The procedure entry Point BaseGetProcessDllPath could not be located in the Dynamic Link library KERNELBASE.dll

View 1 Replies

AJAX :: Combobox Rendering Error In Visual Studio 2008 Design View?

Jan 20, 2010

i am using the combobox ajax control i in design time i am having an error:

there was an error rendering the control. Request is not available in the context.

View 1 Replies

DataSource Controls :: Error When Using Inbuilt Data Connection In Visual Studio 2008?

Jul 11, 2010

Failed to generate a user instance of SQL Server due to failure in retrieving the user's local application data path. make sure the user has a local user profile on the computer. The connection will be closed.

View 1 Replies

Visual Studio :: Connect Visual Web Developer 2008 Express Edition To SQL Server 2008?

Sep 11, 2010

i have created a login.aspx file in visual web developer .now i want to connect the username and password details to SQL database

View 1 Replies

Visual Studio 2008 Debug Error Connecting To Undo Manager Of Source File?

Feb 25, 2011

When i compile my vs2008 solution which is a web application in debug mode i keep getting message box displayed which says that it cannot connect "whatever.designer.cs". Can

View 2 Replies

Compilation Error When Type Sp.DBOperations' Exists

May 8, 2010

The type sp.DBOperations' exists in both c:WINDOWSMicrosoft.NETFrameworkv2.0.50727Temporary ASP.NET Files
ootaf585a885de14bd0assemblydl3966aa64b5c4f1868_c3eeca01sp.DLL' and 'c:WINDOWSMicrosoft.NETFrameworkv2.0.50727Temporary ASP.NET Files
ootaf585a885de14bd0App_Code.m9kl32ja.dll'

View 2 Replies

No Mapping Exists From Object Type Error?

Mar 2, 2011

this is the error i get

[Code]....

View 2 Replies

Visual Studio :: Can Visual Studio 2008 Be All In One Tool To Integrate Source Code Continuously

Jan 20, 2010

can Visual Studio 2008 be All-In-One tool to integrate source code continuously from team members, build, unit test?

Having used Visual Studio Team Edition 2005, unit testing each method within VS itself. I strongly believe that it is feasible to add-on tools. Example ankhsvn tool to use SVN from Visual studio [URL]

In my investigating i have come across number of tools(shown below) to use with Visual Studio 2008 professional

Development tool:- Visual Studio 2008 professional using Subversion as source control tool. Continuous Integration:- Hudson or Cruise control Build tool:- NAnt Testing:- NUnit, Selinium As Visual Studio 2008 can be used for unit testing I think NUnit is out of consideration.

In the same way i would like to have any other tools/add-ons to Visual studio to implement continuous integration, building and unit testing. This process should be automated such a way source code between team members is continuously integrated, built and unit testing is done as configured.

Objective is to use few number of tools as add-on to Visual Studio or achieve most from Visual studio itself (example unit testing). Visual Studio should be all in one tool.

I am aware that Team Foundation Server best suits my requirement, but it is out of scope due to its cost.

View 3 Replies

Configuration :: Error 1706:An Installation Package For The Product Microsoft Visual Studio 2008 Shell(integrated?

Nov 18, 2010

When i was building my project in my local machine it was giving me the below error...."Error 1706:An installation package for the product Microsoft Visual Studio 2008 Shell(integrated mode)ENU cannot be found!!!Try the installation again using a valid copy of the installation package 'vs_shell.msi'"

View 1 Replies

DataSource Controls :: Connecting To SQL Server In Visual Studio 2008 Using Code - Error: 25 - Connection String Is Not Valid

Feb 2, 2010

Background: I use SQL server 2005 developer edition and visual studio 2008. Visual studio 2008 is running on a local machine with Vista business edition. SQL server is running on a remote server using Windows server 2003. Both computers are within the same domain.

Problem: First, I used the server explorer to connect to the SQL server. Everything works as desired. Then I write code to do the same thing. I keep getting the following error message:

A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: SQL Network Interfaces, error: 25 - Connection string is not valid)

However, I used the exactly identical connection string as the one used in the server explorer. So connection string should not be the problem. In addition, I tried the test code in MSDN, which tells whether my domainusername can flow the network. It turns out the user name is fine. I also went to the SQL server management studio and found the login for my computer is NVCWeihao while my computer login name is NVCweihao. I am wondering if this uppercase letter really affects the connection.

View 2 Replies

Compiler Error Type Exists In Two Dynamically Compiled DLLs?

Jun 22, 2010

I've just gone thru a large-ish project and renamed A LOT of namespace directives. Everything works fine on my developer box - deploy it to stage and I get:

Compiler Error Message: CS0433: The type 'ASP.usercontrols_pageheader_ascx' exists in both
'c:WINDOWSMicrosoft.NETFrameworkv2.0.50727Temporary ASP.NET Files
oot89252a5f7305b927App_Web_hodsbmv3.dll' and '
c:WINDOWSMicrosoft.NETFrameworkv2.0.50727Temporary ASP.NET Files
oot89252a5f7305b927App_Web_pageheader.ascx.6bb32623.bs4iljip.dll'

Yuck. Very similar to this: Deployment Project dlls cause 'type x exists in both' errors, but must be coming from a different cause.

I have none of the problems I've seen mentioned in other articles (App_Code / CodeFile directive). Worked out why it works on my machine: the website has no problem when it is in a vdir. If I remove the "PageHeader" usercontrol from the masterpage it lives on everthing is fine. If I rename "PageHeader" everything is fine. Updated: renaming the usercontrol doesn't help.

I'd had a look at the assemblies mentioned in the error in reflector; App_Web_hodsbmv3.dll contains dynamic classes for all the usercontrols in my project. App_Web_pageheader.ascx.6bb32623.bs4iljip.dll' contains the same code just for the PageHeader usercontrol. Why would ASPX decide to create the same class in two assemblies?

View 2 Replies

Visual Studio :: Unable To Install Visual Studio 2008 Professional Edition?

Aug 8, 2010

I downloaded Visual Studio 2008 Professional Edition via torrent.

It was working fine for months & i formatted my comp & when i tried to reinstall it is not getting installed !

It shows the following error !

and the error log file seems to be like this...

BUT.,

I'm able to use Visual Studio & i'm able to work in it....

I'm re-installing since 2 days for more than 4 times...

View 1 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved