473,837 Members | 1,545 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Windows Forms

Just a general question...

When working with a form containing a treeview or similar control... if you
need to show different form fields depending on what is selected in the
treeview then what is the best way to deal with these form controls...?
Like, when they are all visible in the designer it can be absolute chaos...

So how do you guys deal with it? Is there a blank container control (can't
see one) that allows you to drop a screens worth of form controls onto...?
Kinda like the tab control but without the tabs... it's make things easier
to manage... Or do you go to the trouble of setting all form control
properties manually through code making the designer pointless...?

Thanks
Nov 20 '05 #1
6 2354
Cor
Hi

Take a look at "panel" , "groupbox" and to make it complet "statusbar"

For the rest there are a lot of answer.

"User controls", MDI forms, separated forms,
............... ............... ....

Cor
Nov 20 '05 #2
That does nothing to answer the question really... I can see what is in
front of my eyes in the toolbox.... what I want to know is how to best
manage when you have many of these on a single form and you need to flick
from one to the next when setting properties etc... once you have more than
a few of these controls on a form you just get lost and it becomes
unmanagable....

As an example, I have a form with a treeview on the left... on the right I
have a multitude of different controls to display depending on what the user
selects in the treeview... how do I manage all the controls on the right...
just plonk them all on top of each other...?

Ta

"Cor" <no*@non.com> wrote in message
news:%2******** *******@TK2MSFT NGP12.phx.gbl.. .
Hi

Take a look at "panel" , "groupbox" and to make it complet "statusbar"

For the rest there are a lot of answer.

"User controls", MDI forms, separated forms,
............... ............... ...

Cor

Nov 20 '05 #3

Hi,

Thanks for posting in this group.
Windows uses message model to manage all the UI windows(Includi ng
controls). And all the controls have certain events for certain behaviors.
When you do different opertaions on these controls, you can handle related
event, then do the appropriate process.
Because all the controls and UI elements are in the same process,
especially, in the same thread, you can manipulate them freely in the
events.
For example, when you select a certain node of treeview, you can handle the
TreeView_Click event. In this event, you can set the form's text property
as the selected node's text. Or you can add the node's text string into
another listbox.
All these can be done freely.

If I misunderstand you, please feel free to let me know.

Best regards,
Jeffrey Tan
Microsoft Online Partner Support
Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.

--------------------
| From: <->
| References: <uI************ **@TK2MSFTNGP10 .phx.gbl>
<#o************ *@TK2MSFTNGP12. phx.gbl>
| Subject: Re: Windows Forms
| Date: Fri, 14 Nov 2003 09:25:03 +1100
| Lines: 32
| X-Priority: 3
| X-MSMail-Priority: Normal
| X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
| X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
| Message-ID: <eA************ *@TK2MSFTNGP11. phx.gbl>
| Newsgroups: microsoft.publi c.dotnet.langua ges.vb
| NNTP-Posting-Host: 202-44-189-210.nexnet.net. au 202.44.189.210
| Path: cpmsftngxa06.ph x.gbl!TK2MSFTNG P08.phx.gbl!TK2 MSFTNGP11.phx.g bl
| Xref: cpmsftngxa06.ph x.gbl microsoft.publi c.dotnet.langua ges.vb:156676
| X-Tomcat-NG: microsoft.publi c.dotnet.langua ges.vb
|
| That does nothing to answer the question really... I can see what is in
| front of my eyes in the toolbox.... what I want to know is how to best
| manage when you have many of these on a single form and you need to flick
| from one to the next when setting properties etc... once you have more
than
| a few of these controls on a form you just get lost and it becomes
| unmanagable....
|
| As an example, I have a form with a treeview on the left... on the right I
| have a multitude of different controls to display depending on what the
user
| selects in the treeview... how do I manage all the controls on the
right...
| just plonk them all on top of each other...?
|
| Ta
|
|
|
| "Cor" <no*@non.com> wrote in message
| news:%2******** *******@TK2MSFT NGP12.phx.gbl.. .
| > Hi
| >
| > Take a look at "panel" , "groupbox" and to make it complet "statusbar"
| >
| > For the rest there are a lot of answer.
| >
| > "User controls", MDI forms, separated forms,
| > ............... ............... ...
| >
| > Cor
| >
| >
|
|
|

Nov 20 '05 #4
Yep, you misunderstood big time... but thats ok... I'll try to explain...

I have control overload on my form... I have many panels holding form
controls which are shown or hidden depending on what it selected in the
treeview on the left... I find it hard to navigate to a particular form
control on a particular panel (or whatever container I have used)... it
would be handy to be able to place them on a seperate area of the designer
so they can all be viewed at once, but still appear in the correct place
when the app is run...

Currently to navigate to a panel buried under others I have to use the
dropdown list above the Properties window in the .Net IDE... or click on the
topmost one and select send to back... when you have too many controls on
the designer you can't manage them effectively....

Does that explain the problem I have?

Cheers

""Jeffrey Tan[MSFT]"" <v-*****@online.mi crosoft.com> wrote in message
news:6o******** ******@cpmsftng xa06.phx.gbl...

Hi,

Thanks for posting in this group.
Windows uses message model to manage all the UI windows(Includi ng
controls). And all the controls have certain events for certain behaviors.
When you do different opertaions on these controls, you can handle related
event, then do the appropriate process.
Because all the controls and UI elements are in the same process,
especially, in the same thread, you can manipulate them freely in the
events.
For example, when you select a certain node of treeview, you can handle the TreeView_Click event. In this event, you can set the form's text property
as the selected node's text. Or you can add the node's text string into
another listbox.
All these can be done freely.

If I misunderstand you, please feel free to let me know.

Best regards,
Jeffrey Tan
Microsoft Online Partner Support
Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.

--------------------
| From: <->
| References: <uI************ **@TK2MSFTNGP10 .phx.gbl>
<#o************ *@TK2MSFTNGP12. phx.gbl>
| Subject: Re: Windows Forms
| Date: Fri, 14 Nov 2003 09:25:03 +1100
| Lines: 32
| X-Priority: 3
| X-MSMail-Priority: Normal
| X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
| X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
| Message-ID: <eA************ *@TK2MSFTNGP11. phx.gbl>
| Newsgroups: microsoft.publi c.dotnet.langua ges.vb
| NNTP-Posting-Host: 202-44-189-210.nexnet.net. au 202.44.189.210
| Path: cpmsftngxa06.ph x.gbl!TK2MSFTNG P08.phx.gbl!TK2 MSFTNGP11.phx.g bl
| Xref: cpmsftngxa06.ph x.gbl microsoft.publi c.dotnet.langua ges.vb:156676
| X-Tomcat-NG: microsoft.publi c.dotnet.langua ges.vb
|
| That does nothing to answer the question really... I can see what is in
| front of my eyes in the toolbox.... what I want to know is how to best
| manage when you have many of these on a single form and you need to flick | from one to the next when setting properties etc... once you have more
than
| a few of these controls on a form you just get lost and it becomes
| unmanagable....
|
| As an example, I have a form with a treeview on the left... on the right I | have a multitude of different controls to display depending on what the
user
| selects in the treeview... how do I manage all the controls on the
right...
| just plonk them all on top of each other...?
|
| Ta
|
|
|
| "Cor" <no*@non.com> wrote in message
| news:%2******** *******@TK2MSFT NGP12.phx.gbl.. .
| > Hi
| >
| > Take a look at "panel" , "groupbox" and to make it complet "statusbar" | >
| > For the rest there are a lot of answer.
| >
| > "User controls", MDI forms, separated forms,
| > ............... ............... ...
| >
| > Cor
| >
| >
|
|
|

Nov 20 '05 #5
How about creating them all as docked MDI forms.. Have the treeview in an
mdi form docked to the left hand side, and then just load up the correct
form as an mdi in code docked to the right.

Will that work for you ?

HTH
Simon
<-> wrote in message news:ev******** ******@TK2MSFTN GP12.phx.gbl...
Yep, you misunderstood big time... but thats ok... I'll try to explain...

I have control overload on my form... I have many panels holding form
controls which are shown or hidden depending on what it selected in the
treeview on the left... I find it hard to navigate to a particular form
control on a particular panel (or whatever container I have used)... it
would be handy to be able to place them on a seperate area of the designer
so they can all be viewed at once, but still appear in the correct place
when the app is run...

Currently to navigate to a panel buried under others I have to use the
dropdown list above the Properties window in the .Net IDE... or click on the topmost one and select send to back... when you have too many controls on
the designer you can't manage them effectively....

Does that explain the problem I have?

Cheers

""Jeffrey Tan[MSFT]"" <v-*****@online.mi crosoft.com> wrote in message
news:6o******** ******@cpmsftng xa06.phx.gbl...

Hi,

Thanks for posting in this group.
Windows uses message model to manage all the UI windows(Includi ng
controls). And all the controls have certain events for certain behaviors. When you do different opertaions on these controls, you can handle related event, then do the appropriate process.
Because all the controls and UI elements are in the same process,
especially, in the same thread, you can manipulate them freely in the
events.
For example, when you select a certain node of treeview, you can handle the
TreeView_Click event. In this event, you can set the form's text property as the selected node's text. Or you can add the node's text string into
another listbox.
All these can be done freely.

If I misunderstand you, please feel free to let me know.

Best regards,
Jeffrey Tan
Microsoft Online Partner Support
Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.
--------------------
| From: <->
| References: <uI************ **@TK2MSFTNGP10 .phx.gbl>
<#o************ *@TK2MSFTNGP12. phx.gbl>
| Subject: Re: Windows Forms
| Date: Fri, 14 Nov 2003 09:25:03 +1100
| Lines: 32
| X-Priority: 3
| X-MSMail-Priority: Normal
| X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
| X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
| Message-ID: <eA************ *@TK2MSFTNGP11. phx.gbl>
| Newsgroups: microsoft.publi c.dotnet.langua ges.vb
| NNTP-Posting-Host: 202-44-189-210.nexnet.net. au 202.44.189.210
| Path: cpmsftngxa06.ph x.gbl!TK2MSFTNG P08.phx.gbl!TK2 MSFTNGP11.phx.g bl
| Xref: cpmsftngxa06.ph x.gbl microsoft.publi c.dotnet.langua ges.vb:156676
| X-Tomcat-NG: microsoft.publi c.dotnet.langua ges.vb
|
| That does nothing to answer the question really... I can see what is in | front of my eyes in the toolbox.... what I want to know is how to best
| manage when you have many of these on a single form and you need to

flick
| from one to the next when setting properties etc... once you have more
than
| a few of these controls on a form you just get lost and it becomes
| unmanagable....
|
| As an example, I have a form with a treeview on the left... on the right I
| have a multitude of different controls to display depending on what

the user
| selects in the treeview... how do I manage all the controls on the
right...
| just plonk them all on top of each other...?
|
| Ta
|
|
|
| "Cor" <no*@non.com> wrote in message
| news:%2******** *******@TK2MSFT NGP12.phx.gbl.. .
| > Hi
| >
| > Take a look at "panel" , "groupbox" and to make it complet

"statusbar"
| >
| > For the rest there are a lot of answer.
| >
| > "User controls", MDI forms, separated forms,
| > ............... ............... ...
| >
| > Cor
| >
| >
|
|
|


Nov 20 '05 #6

Hi,

Sorry for misunderstandin g you.
For this issue, I think it is by the design of the form designer, the
control overlapped on another, this depands on the z-order.(Normally , it
depands on the order in the code it being added into the controls
collection).
If you have many panel one on another, I think you can select different
control from the property's dropdownlist to select you wanted control, use
right click menu to set it to front.
Also, you can go to the code editor, to change its z-order(by changing the
order it being added int the controls collection)

Best regards,
Jeffrey Tan
Microsoft Online Partner Support
Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.

--------------------
| From: <->
| References: <uI************ **@TK2MSFTNGP10 .phx.gbl>
<#o************ *@TK2MSFTNGP12. phx.gbl>
<eA************ *@TK2MSFTNGP11. phx.gbl>
<6o************ **@cpmsftngxa06 .phx.gbl>
| Subject: Re: Windows Forms
| Date: Fri, 14 Nov 2003 19:59:31 +1100
| Lines: 107
| X-Priority: 3
| X-MSMail-Priority: Normal
| X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
| X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
| Message-ID: <ev************ **@TK2MSFTNGP12 .phx.gbl>
| Newsgroups: microsoft.publi c.dotnet.langua ges.vb
| NNTP-Posting-Host: 202-44-189-210.nexnet.net. au 202.44.189.210
| Path: cpmsftngxa06.ph x.gbl!TK2MSFTNG P08.phx.gbl!TK2 MSFTNGP12.phx.g bl
| Xref: cpmsftngxa06.ph x.gbl microsoft.publi c.dotnet.langua ges.vb:156775
| X-Tomcat-NG: microsoft.publi c.dotnet.langua ges.vb
|
| Yep, you misunderstood big time... but thats ok... I'll try to explain...
|
| I have control overload on my form... I have many panels holding form
| controls which are shown or hidden depending on what it selected in the
| treeview on the left... I find it hard to navigate to a particular form
| control on a particular panel (or whatever container I have used)... it
| would be handy to be able to place them on a seperate area of the designer
| so they can all be viewed at once, but still appear in the correct place
| when the app is run...
|
| Currently to navigate to a panel buried under others I have to use the
| dropdown list above the Properties window in the .Net IDE... or click on
the
| topmost one and select send to back... when you have too many controls on
| the designer you can't manage them effectively....
|
| Does that explain the problem I have?
|
| Cheers
|
| ""Jeffrey Tan[MSFT]"" <v-*****@online.mi crosoft.com> wrote in message
| news:6o******** ******@cpmsftng xa06.phx.gbl...
| >
| > Hi,
| >
| > Thanks for posting in this group.
| > Windows uses message model to manage all the UI windows(Includi ng
| > controls). And all the controls have certain events for certain
behaviors.
| > When you do different opertaions on these controls, you can handle
related
| > event, then do the appropriate process.
| > Because all the controls and UI elements are in the same process,
| > especially, in the same thread, you can manipulate them freely in the
| > events.
| > For example, when you select a certain node of treeview, you can handle
| the
| > TreeView_Click event. In this event, you can set the form's text
property
| > as the selected node's text. Or you can add the node's text string into
| > another listbox.
| > All these can be done freely.
| >
| > If I misunderstand you, please feel free to let me know.
| >
| > Best regards,
| > Jeffrey Tan
| > Microsoft Online Partner Support
| > Get Secure! - www.microsoft.com/security
| > This posting is provided "as is" with no warranties and confers no
rights.
| >
| > --------------------
| > | From: <->
| > | References: <uI************ **@TK2MSFTNGP10 .phx.gbl>
| > <#o************ *@TK2MSFTNGP12. phx.gbl>
| > | Subject: Re: Windows Forms
| > | Date: Fri, 14 Nov 2003 09:25:03 +1100
| > | Lines: 32
| > | X-Priority: 3
| > | X-MSMail-Priority: Normal
| > | X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
| > | X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
| > | Message-ID: <eA************ *@TK2MSFTNGP11. phx.gbl>
| > | Newsgroups: microsoft.publi c.dotnet.langua ges.vb
| > | NNTP-Posting-Host: 202-44-189-210.nexnet.net. au 202.44.189.210
| > | Path: cpmsftngxa06.ph x.gbl!TK2MSFTNG P08.phx.gbl!TK2 MSFTNGP11.phx.g bl
| > | Xref: cpmsftngxa06.ph x.gbl microsoft.publi c.dotnet.langua ges.vb:156676
| > | X-Tomcat-NG: microsoft.publi c.dotnet.langua ges.vb
| > |
| > | That does nothing to answer the question really... I can see what is
in
| > | front of my eyes in the toolbox.... what I want to know is how to best
| > | manage when you have many of these on a single form and you need to
| flick
| > | from one to the next when setting properties etc... once you have more
| > than
| > | a few of these controls on a form you just get lost and it becomes
| > | unmanagable....
| > |
| > | As an example, I have a form with a treeview on the left... on the
right
| I
| > | have a multitude of different controls to display depending on what
the
| > user
| > | selects in the treeview... how do I manage all the controls on the
| > right...
| > | just plonk them all on top of each other...?
| > |
| > | Ta
| > |
| > |
| > |
| > | "Cor" <no*@non.com> wrote in message
| > | news:%2******** *******@TK2MSFT NGP12.phx.gbl.. .
| > | > Hi
| > | >
| > | > Take a look at "panel" , "groupbox" and to make it complet
| "statusbar"
| > | >
| > | > For the rest there are a lot of answer.
| > | >
| > | > "User controls", MDI forms, separated forms,
| > | > ............... ............... ...
| > | >
| > | > Cor
| > | >
| > | >
| > |
| > |
| > |
| >
|
|
|

Nov 20 '05 #7

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

Similar topics

2
3810
by: Greg Bacchus | last post by:
Hi, I'm getting an exception that really has me stumped. It's sporadic at best, it's only happened a handful of times. This particular time it happened when the user pressed 'Alt-S' to save the data that they were entering. Following is all exception information. Any thoughts much appreciated. Cheers
15
3922
by: Wiktor Zychla | last post by:
today we've found a critical issue regarding the ListView from Windows.Forms. it was confirmed on several machines with Win2K and XP. here's the problem: create a ListView with about 50000 rows. now use task manager to see the GDI usage of the process. everything seems normal. now catch the ListView's scroller and start to move it downwards. you have to hold the constant speed so that the ListView is constantly repainted. look at the...
5
1820
by: david | last post by:
I have developed my web service with a domain name of my computer name and wwwroot directory. I also developed a client of windows form application. It works locally (i.e. in the same machine). When I copy my client application to another machine and start it, I got an error about initialized problem. Note that I can browser my web service .asmx file from the second machine. The sample client source code:
7
2640
by: Tyler Foreman | last post by:
Hello, I have a strange problem that occurs every so often in my application. It usually takes place when I hide one form and activate another. What happens is I get the following exception: System.ArgumentException occured in System.Windows.Forms.dll
1
3457
by: Scott Davies | last post by:
Hi, I'm looking for some help on a small program that I'm trying to develop in VB.NET. I'm having trouble getting the code that I've written to work, can anyone shed some light as to where I'm going wrong. The program has been written to do the following tasks: - Select remote server - Select from two specific services
0
3946
by: Scott Davies | last post by:
Hi, I'm looking for some help on a small program that I'm trying to develop in VB.NET. The program I'm trying to develop needs to be able to do the following: - Select remote server - Select from two specific services - Check the status of the server
4
3165
by: Rod Gill | last post by:
Hi, I have a form that when opened in the designer appears of the screen. The form selector can't be dragged (or resized) and if I scroll right and down to centralise it the form simply jumps further away, completely leaving the selector box area. Any ideas? VS 2003 and VB.Net This is a simple application at the moment but the form is inherited from a
4
4191
by: tshad | last post by:
What would be a good way to check programmatically whether a service was running? We have a service that dies periodically and I need to check to see if this service is running. I know how to check to see if the status is in stopped or running mode. But that doesn't tell me if it is actually running. I need to know this so that if it happens I can programmatically start the same service on another machine.
1
7858
by: mfunkmann | last post by:
Hi, I recently got an error and I don't know how to fix it: Error 1 'System.Data.DataColumn' does not contain a definition for 'Windows' C:\c#\CsharpPRO\Form1.Designer.cs 304 77 CsharpPRO I am note sure what to do because all propertiers work, except the System.Data.DataColumn.. I didn't write any code by hand and used the visual studio to set the properties..
21
3397
by: Dan Tallent | last post by:
In my application I have a form (Customer) that I want to be able to open multiple copies at once. Within this form I have other forms that can be opened. Example: ZipCode. When the user enters a zipcode that is unknown this form will open. I don't want users to modify any of this customers data until they close the zipcode form. Normally this can accomplished using a modal form, however this prevents me from opening a new copy of...
0
9683
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
10882
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
10577
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
9407
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
7005
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
5670
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5851
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4476
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
3
3126
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.