Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > Renamed aspx file in VS .NET 2005, now won't build

Reply
Thread Tools

Renamed aspx file in VS .NET 2005, now won't build

 
 
Brent White
Guest
Posts: n/a
 
      10-28-2005
The aspx file was originally default.aspx, but I'm putting some other
aspx files in that same virtual directory and I want to give it a more
meaningful name. I renamed default.aspx in the IDE to
CorporateSelectStates.aspx, and the file default.aspx.vb was renamed to
CorporateSelectStates.aspx.vb.

Now when I try to build, I get an error saying "The file
/CrystalReportsWebApplication1/Default.aspx.vb does not exist"

It refers to line 1 of the aspx file, but this is the aspx file in its
entirety (it's not a lot of code):

<%@ Page Language="VB" AutoEventWireup="false"
CodeFile="CorporateSelectStates.aspx.vb" Inherits="_Default" %>
<%@ Register TagPrefix="CR" Namespace="CrystalDecisions.Web"
Assembly="CrystalDecisions.Web, Version=10.2.3600.0, Culture=neutral,
PublicKeyToken=692fbea5521e1304" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
<title>Corporate Customer List</title>
</head>
<body>
<form id="form1" runat="server">
<div>
<asp:TextBox ID="TextBox1" runat="server"></asp:TextBox><br />
<asp:Button ID="Button1" runat="server" Text="Button" /><br />
<br />
<br />
<br />
<br />
<CR:CrystalReportViewer ID="CrystalReportViewer1"
Runat="server" AutoDataBind="True"
Height="815px" CssFilename="/css/default.css"
ReportSourceID="CrystalReportSource2" Width="1200px"
PrintMode="ActiveX" />
<CR:CrystalReportSource ID="CrystalReportSource2"
runat="server" GroupPath="">
<Report FileName="CorporateCustomerListSelectState.rpt">
</Report>
</CR:CrystalReportSource>
</div>


</form>
</body>
</html>


There is a class "_default" in the aspx.vb file, so I knwo it's not
that. What did I do wrong or is this a bug in VS .NET 2005?

 
Reply With Quote
 
 
 
 
Juan T. Llibre
Guest
Posts: n/a
 
      10-28-2005
That's what happens when you inherit from a non-existing object.

Replace all instances of "Default" with "CorporateSelectStates"
in both the aspx *and* in the codebehind, and it will compile OK.

That would include renaming "_Default" to "_CorporateSelectStates"



Juan T. Llibre, ASP.NET MVP
ASP.NET FAQ : http://asp.net.do/faq/
Foros de ASP.NET en Espaņol : http://asp.net.do/foros/
======================================
"Brent White" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed) oups.com...
> The aspx file was originally default.aspx, but I'm putting some other
> aspx files in that same virtual directory and I want to give it a more
> meaningful name. I renamed default.aspx in the IDE to
> CorporateSelectStates.aspx, and the file default.aspx.vb was renamed to
> CorporateSelectStates.aspx.vb.
>
> Now when I try to build, I get an error saying "The file
> /CrystalReportsWebApplication1/Default.aspx.vb does not exist"
>
> It refers to line 1 of the aspx file, but this is the aspx file in its
> entirety (it's not a lot of code):
>
> <%@ Page Language="VB" AutoEventWireup="false"
> CodeFile="CorporateSelectStates.aspx.vb" Inherits="_Default" %>
> <%@ Register TagPrefix="CR" Namespace="CrystalDecisions.Web"
> Assembly="CrystalDecisions.Web, Version=10.2.3600.0, Culture=neutral,
> PublicKeyToken=692fbea5521e1304" %>
>
> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
> "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
>
> <html xmlns="http://www.w3.org/1999/xhtml" >
> <head runat="server">
> <title>Corporate Customer List</title>
> </head>
> <body>
> <form id="form1" runat="server">
> <div>
> <asp:TextBox ID="TextBox1" runat="server"></asp:TextBox><br />
> <asp:Button ID="Button1" runat="server" Text="Button" /><br />
> <br />
> <br />
> <br />
> <br />
> <CR:CrystalReportViewer ID="CrystalReportViewer1"
> Runat="server" AutoDataBind="True"
> Height="815px" CssFilename="/css/default.css"
> ReportSourceID="CrystalReportSource2" Width="1200px"
> PrintMode="ActiveX" />
> <CR:CrystalReportSource ID="CrystalReportSource2"
> runat="server" GroupPath="">
> <Report FileName="CorporateCustomerListSelectState.rpt">
> </Report>
> </CR:CrystalReportSource>
> </div>
>
>
> </form>
> </body>
> </html>
>
>
> There is a class "_default" in the aspx.vb file, so I knwo it's not
> that. What did I do wrong or is this a bug in VS .NET 2005?
>



 
Reply With Quote
 
 
 
 
Brent
Guest
Posts: n/a
 
      10-28-2005
Okay, that worked (I probably would have done that eventually anyway).

--
Sent via .NET Newsgroups
http://www.dotnetnewsgroups.com
 
Reply With Quote
 
Guadala Harry
Guest
Posts: n/a
 
      10-28-2005
<< I probably would have done that eventually anyway >>

What's that supposed to mean?



"Brent" <(E-Mail Removed)> wrote in message
news:%23$(E-Mail Removed)...
> Okay, that worked (I probably would have done that eventually anyway).
>
> --
> Sent via .NET Newsgroups
> http://www.dotnetnewsgroups.com



 
Reply With Quote
 
Brent
Guest
Posts: n/a
 
      10-28-2005
I mean renamed all the classes.

--
Sent via .NET Newsgroups
http://www.dotnetnewsgroups.com
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
error "Unable to read the project file .. The project file ' ' has been renamed or is no longer in the solution Amarpal ASP General 2 12-31-2011 02:44 AM
Remote AspNetdb, Renamed Database . Now error: 'InstallCommon.sql' jobs ASP .Net 0 07-19-2007 09:51 PM
Control Events renamed in ASPX - What a shame Mikeon ASP .Net 2 03-16-2006 02:51 PM
SWsoft Acronis Disk Director Suite 9.0 Build 508, Acronis OS Selector 8.0 Build 917, Acronis Partition Expert 2003 Build 292, Acronis Power Utilities 2004 Build 502, F-SECURE.ANTI vIRUS.PROXY v1.10.17.WINALL, F-SECURE.ANTI vIRUS v5.50.10260 for CITRI vvcd Computer Support 0 09-25-2004 01:38 AM
Can a .aspx file be renamed to .htm? Bruce W...1 ASP .Net 11 08-23-2003 11:04 PM



Advertisments