473,394 Members | 1,715 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,394 software developers and data experts.

Can't find Partial Code file

Hi guys!

it's me againe! this time i'm facing some problem with the .NET 2005
IDE.
i've created one "website" and i've added one webform. now i can see 2
files default.aspx and default.aspx.cs but i can see the "Windows
Generated Code" in CS file.
i searched for it and found that that code is written in the
default.Designer.aspx.cs but what surprised me is THAT FILE DOESNT
EXISTS in my project neigther in the web folder.

anyone know what could be the problem? i need to find out that
InitializeComponent() method to add some custom code for initializing
other component.

please help me out.

Lucky

Jun 14 '06 #1
3 2949
Hi,

No more .net generated code for aspx pages. its changed in .net 2. the
partial class for the aspx controls will be generated dynamically at
runtime. write your code page_load or oninit.

"Lucky" <tu************@gmail.com> wrote in message
news:11**********************@y43g2000cwc.googlegr oups.com...
Hi guys!

it's me againe! this time i'm facing some problem with the .NET 2005
IDE.
i've created one "website" and i've added one webform. now i can see 2
files default.aspx and default.aspx.cs but i can see the "Windows
Generated Code" in CS file.
i searched for it and found that that code is written in the
default.Designer.aspx.cs but what surprised me is THAT FILE DOESNT
EXISTS in my project neigther in the web folder.

anyone know what could be the problem? i need to find out that
InitializeComponent() method to add some custom code for initializing
other component.

please help me out.

Lucky

Jun 14 '06 #2
Thanks Pal,
I had this doubt but i didnt find any blog on that so far and the book
i have says that there is a designer code in different file so i was
quite confused.

thanks for help,
Lucky
Balasubramanian Ramanathan wrote:
Hi,

No more .net generated code for aspx pages. its changed in .net 2. the
partial class for the aspx controls will be generated dynamically at
runtime. write your code page_load or oninit.

"Lucky" <tu************@gmail.com> wrote in message
news:11**********************@y43g2000cwc.googlegr oups.com...
Hi guys!

it's me againe! this time i'm facing some problem with the .NET 2005
IDE.
i've created one "website" and i've added one webform. now i can see 2
files default.aspx and default.aspx.cs but i can see the "Windows
Generated Code" in CS file.
i searched for it and found that that code is written in the
default.Designer.aspx.cs but what surprised me is THAT FILE DOESNT
EXISTS in my project neigther in the web folder.

anyone know what could be the problem? i need to find out that
InitializeComponent() method to add some custom code for initializing
other component.

please help me out.

Lucky


Jun 14 '06 #3
ASP.NET 2.0 is completelly diferent from ASP.NET 1.1 in that matter
you do not have code written by the VS on files.

when you create a new page you have the chance to have a separate code file
(check the checkbox for that) and choose a master page file (below that
opition).

just add the page to your project add some code inside the DIV tag that is
inside the form like "Hello World", click with the right mouse button and
choose see in browser to see it

the only code that VS add's to the code file (if you choose this options) is
a particial class and in the aspx page it mentions the codefile="" and
inherits=""

in the default.aspx.vb
Partial Class Default2 Inherits System.Web.UI.Page

End Class

and in aspx page:
<%@ Page ... CodeFile="Default2.aspx.vb" Inherits="Default2" ...

if you still have the blue underline, just change the Class Name and the
Inherits to a name without _ (underlines)

--

Bruno Alexandre
(a Portuguese in Københanv, Danmark)
"Lucky" <tu************@gmail.com> escreveu na mensagem
news:11**********************@y43g2000cwc.googlegr oups.com...
Hi guys!

it's me againe! this time i'm facing some problem with the .NET 2005
IDE.
i've created one "website" and i've added one webform. now i can see 2
files default.aspx and default.aspx.cs but i can see the "Windows
Generated Code" in CS file.
i searched for it and found that that code is written in the
default.Designer.aspx.cs but what surprised me is THAT FILE DOESNT
EXISTS in my project neigther in the web folder.

anyone know what could be the problem? i need to find out that
InitializeComponent() method to add some custom code for initializing
other component.

please help me out.

Lucky

Jun 14 '06 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

9
by: Gomaw Beoyr | last post by:
Two question about the "partial classes" (in the next wersion of ..NET). Question 1 ========== Will partial classes (in the next version of C#) have to be declared "partial" in ALL places. ...
21
by: nospam | last post by:
Ok, I asked this question before and I also looked at the book "First Look at ASP.NET 2.0" I also read Paul wilson's web page explanation. HOWEVER...... The book and that web page talks about...
7
by: Patrick | last post by:
Hi all, I was playing around with ASP.Net 2.0 and recognized that in case you use Code-Behind/Beside (how is it called in future?) the parser still creates TWO classes one partial class under...
16
by: pawel.pabich | last post by:
Hajo, I would like to have 2 my own partial classes. For example: Default.aspx.cs Default2.aspx.cs and they both will relate to Default.aspx page.
4
by: Brett Romero | last post by:
I have a .NET 1.1 form that was migrated into 2.0. Its class file is in form1.cs. I've created another "code" file named form1.designer.cs and with this code: partial class form1 in the...
9
by: Fat Elvis | last post by:
I'd like to extend some of my Asp.net pages by using Partial Classes. Example ASP.Net Page: public partial class Admin_Customer : System.Web.UI.Page { protected void Page_Load(object sender,...
4
by: Michael Rodriguez | last post by:
Is it possible to have a Windows form that is declared as a generic type, i.e.: public partial class DataEntry<T, C: DataEntryBase where T: ... where C: ... I tried that, but it chokes on...
2
by: tbh | last post by:
hi, hope this cross-post is OK. it's unclear to me whether this question belongs more under vstudio or dotnet... i'm using VS2005 pro and am one co-developer of a web solution that is getting to...
4
by: =?Utf-8?B?VG9yZW4gVmFsb25l?= | last post by:
Was editing code, am getting the following errors } expected Type or namespace definition, or end-of-file expected Eyes crossed cannot find code below! using System; using...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.