473,795 Members | 2,875 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

How To Show Partial Classes as a Hierarchy in Solution Explorer?

In VS2005, creating a new form creates the form class and a partial
(frm*.designer. vb) class file and displays the partial class beneath
the main
form frm*.vb, which is great. However, when extracting the designer
code
elements from an existing form class into its own partial class, (or
creating new ones) the partial
class is displayed in the Solution Explorer under the Project name,
that is,
at the same level as the file from which it came.

Q: How can the partial file be displayed as a "sub-file" as a newly
created
form fle in VS2005?

Jun 20 '06 #1
3 3195
Hi Erich,

You need to copy the both the .designer and .vb in the project location
and then add only the .vb class asa an existing item, the IDE should
find the partial class and associate it automatically. Make sure you
got the name of the Partial Class correctly.

Cheers
er***@softwares ourcery.com a écrit :
In VS2005, creating a new form creates the form class and a partial
(frm*.designer. vb) class file and displays the partial class beneath
the main
form frm*.vb, which is great. However, when extracting the designer
code
elements from an existing form class into its own partial class, (or
creating new ones) the partial
class is displayed in the Solution Explorer under the Project name,
that is,
at the same level as the file from which it came.

Q: How can the partial file be displayed as a "sub-file" as a newly
created
form fle in VS2005?


Jun 20 '06 #2
Hi Erich,

You need to copy the both the .designer and .vb in the project location
and then add only the .vb class as an existing item, the IDE should
find the partial class and associate it automatically. Make sure you
got the name of the Partial Class correctly.

Cheers
er***@softwares ourcery.com a écrit :
In VS2005, creating a new form creates the form class and a partial
(frm*.designer. vb) class file and displays the partial class beneath
the main
form frm*.vb, which is great. However, when extracting the designer
code
elements from an existing form class into its own partial class, (or
creating new ones) the partial
class is displayed in the Solution Explorer under the Project name,
that is,
at the same level as the file from which it came.

Q: How can the partial file be displayed as a "sub-file" as a newly
created
form fle in VS2005?


Jun 20 '06 #3
Hi Krishn...@gmail .com

Thanks for the reply, but that didn't work. Following your procedure
resulted in only the .vb file being displayed in the Solution Explorer.
My other partial class files did not display.

I found another post on the ms public dotnetlang.csha rp group where, at
least in C#, editing the project file (in his case the csproj file) and
adding the <DependentUpo n> tags to the partial file entries allegedly
makes the partial files display under the 'main' file, but I could not
get that procedure to work in VB either. Any other ideas?

Thanks

Erich

kr*******@gmail .com wrote:
Hi Erich,

You need to copy the both the .designer and .vb in the project location
and then add only the .vb class as an existing item, the IDE should
find the partial class and associate it automatically. Make sure you
got the name of the Partial Class correctly.

Cheers
er***@softwares ourcery.com a écrit :
In VS2005, creating a new form creates the form class and a partial
(frm*.designer. vb) class file and displays the partial class beneath
the main
form frm*.vb, which is great. However, when extracting the designer
code
elements from an existing form class into its own partial class, (or
creating new ones) the partial
class is displayed in the Solution Explorer under the Project name,
that is,
at the same level as the file from which it came.

Q: How can the partial file be displayed as a "sub-file" as a newly
created
form fle in VS2005?


Jun 21 '06 #4

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

Similar topics

43
2678
by: nospam | last post by:
I got three (3) files (1) Untitled.aspx (2) Untitled.aspx.1.cs (3) Untitled.aspx.2.cs These three files must be used together to make file #1, Untitled.aspx, page work via J.I.T. when the User first hits Internet Explorer 6.0 on your browser.
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:
1
1324
by: Stuart Ferguson | last post by:
I am currently in the process of workin on Software in C# that has been converted to VS2005 from VS2003. My question is thet when i create a Windows Form it gets created as a partial class with 3 files per each form in the solution explorer, is this correct or is this an option that can be turned off ? Stuart
10
2446
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
4
2231
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 same namespace as form1. form1.cs declares its class as public partial class form1: Form
10
1974
by: Phil Townsend | last post by:
Hello, I have come to like just about everything in VS2005 except for the "partial class" feature. Sometimes when I add a control to a web form, it is not referenced in the partial class . Before VS2005 I could simply add my own reference, now I can't. Where can I find the other "part" of the class? Or even better, is there a way to disable this feature? Thanks!
4
7414
by: Sami Rehman | last post by:
Hi I want to use namespaces to organize all the classes, web forms, and user controls. It works fine with my user defined classes, but when I try to put all the web pages in a namespace for example namespace myCompany. MyApp.Web { } the page starts throwing error, and rightly so because, its a partial class public partial class _Default : System.Web.UI.Page and the other part of it is not in the same namespace. The error message in
2
5566
by: Joseph Geretz | last post by:
When I create a Form, the VB IDE creates the following files in the following hierarchy: Form1.cs Form1.Designer.cs Form1.resx Both Form1.cs and Form1.Designer.cs are partial implementations of a single physical class definition. The VB IDE properly recognizes Form1.cs as a Form (i.e. double-clicking opens the Form designer). It also recognizes
3
1498
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.
0
9673
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
9522
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
10002
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
9044
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...
1
7543
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6783
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();...
1
4113
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3728
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2921
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.