473,769 Members | 5,205 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Can I avoid Partial classes in VS.Net 2005 ?

I am working on a migration project for a huge asp.net application now
running in framwework 1.1 to dotnet 2.0

As a first step, I opened the .sln files of the project in VS.Net
2005. The Conversion wizard created partial classes off the existing
classes.

Is partial classes mandatory in VS.Net 2005 or can I still work
without having to live with partial classes ?

thanks
Anand
Nov 22 '07 #1
5 1372
What do you expect to gain by not using partial classes ?

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/
=============== =============== ========
"Sagar" <an********@gma il.comwrote in message
news:9c******** *************** ***********@d61 g2000hsa.google groups.com...
>I am working on a migration project for a huge asp.net application now
running in framwework 1.1 to dotnet 2.0

As a first step, I opened the .sln files of the project in VS.Net
2005. The Conversion wizard created partial classes off the existing
classes.

Is partial classes mandatory in VS.Net 2005 or can I still work
without having to live with partial classes ?

thanks
Anand

Nov 22 '07 #2
In my migration tests, I've found that the .aspx/.aspx.vb files migrated
without any modifications to using partial classes (and from my reading, it
should not convert existing pages to use them). After migrating, you *can*
convert them to use partial classes if you were to right click on the
project or file and choose "Convert To Web Application" (see:
http://msdn2.microsoft.com/en-us/lib...x#wapp_topic18
and look at "Step 6: Covert Code-Behind Classes to Partial Classes").

So no, partial classes are NOT required.

"Sagar" <an********@gma il.comwrote in message
news:9c******** *************** ***********@d61 g2000hsa.google groups.com...
>I am working on a migration project for a huge asp.net application now
running in framwework 1.1 to dotnet 2.0

As a first step, I opened the .sln files of the project in VS.Net
2005. The Conversion wizard created partial classes off the existing
classes.

Is partial classes mandatory in VS.Net 2005 or can I still work
without having to live with partial classes ?

thanks
Anand
Nov 22 '07 #3
Partial classes are not required. But you should move in that direction
as fast as you can.

-----Original Message-----
From: Sagar [mailto:an****** **@gmail.com]
Posted At: Thursday, November 22, 2007 8:22 AM
Posted To: microsoft.publi c.dotnet.framew ork.aspnet
Conversation: Can I avoid Partial classes in VS.Net 2005 ?
Subject: Can I avoid Partial classes in VS.Net 2005 ?

I am working on a migration project for a huge asp.net application now
running in framwework 1.1 to dotnet 2.0

As a first step, I opened the .sln files of the project in VS.Net
2005. The Conversion wizard created partial classes off the existing
classes.

Is partial classes mandatory in VS.Net 2005 or can I still work
without having to live with partial classes ?

thanks
Anand

Nov 22 '07 #4
Thanks, I am basically looking towards minimal changes to code yet get
the full benefit of .net 2.0.

- Anand
an********@gmai l.com
Nov 22 '07 #5
Once you come to an understanding of why partial classes are useful, it won't
be such a big deal I believe.

--Peter
"Inside every large program, there is a small program trying to get out."
http://www.eggheadcafe.com
http://petesbloggerama.blogspot.com
http://www.blogmetafinder.com

"Sagar" wrote:
Thanks, I am basically looking towards minimal changes to code yet get
the full benefit of .net 2.0.

- Anand
an********@gmai l.com
Nov 22 '07 #6

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

Similar topics

9
2534
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. I.e. do we have to need to write:
7
1637
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 the global namespace which is called the same way than your codebehind class and another class under ASP namespace which is called the way you named your ASPX file (using underscores instead of dots). It's not enough, it playces the files you...
7
1035
by: Adrian Parker | last post by:
In 2003, we have a usercontrol that we reference as a type i.e. we can pass the class around to functions to reference it. In 2005, the class is now partial and doesn't seem to let you reference it as a type anymore, is there a way around this ? Thanks Adrian
16
2652
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.
10
2445
by: ptass | last post by:
Hi In asp.net 2.0 an aspx files .cs file is a partial class and all works fine, however, I thought I’d be able to create another class file, call it a partial class and have that compile and load as a 3rd partial class. This would be handy so i can generate standard code into one of the partial classes, while having my custom code untouched
9
3266
by: TheSteph | last post by:
In VS 2005 Form files are in 3 parts : From1.cs, Form1.Designer.cs and Form1.resx. In VS 2003 there is only one ".cs files". How can I split my old VS2003 ".cs files" files in 2 files : From.cs and Form.Designer.cs, and get thoses file "grouped" in the Solution explorer under the main Form.cs file ?
2
1429
by: Sebastian | last post by:
Hi Everyone, we're currently developing an web-app for insurance company. We've got a long form-flows and view-classes (MVC) of about 2000 lines of code. Is there any possibility to split code-behind classes into multiple files using partial classes? It would be helpfull to balance work on multiple developers working on same subject. I've already got it done in DLL-Projects (SQL-Helper, Builders, .... ) but how to do it in web-projects?
3
1497
by: =?Utf-8?B?TWljaGFlbCBkZSBWZXJh?= | last post by:
Just curios to know why a vb class is referred to as partial class. Especially after adding this item to your project. Thanks for any clarifications.
2
2128
by: Peted | last post by:
Hi, im moving a project from vs2005 to vs 2008. is doing so i have come across a compiler error regarding partial classes that i dont understand if anyone can explain it to me please the orig defintion that compiles and runs fine in vs2005 is bellow......
0
9589
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9423
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10222
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10050
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
9866
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
8876
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
6675
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5448
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
3570
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.