Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Windows Forms / Design Time / October 2005

Tip: Looking for answers? Try searching our database.

2-way Splitter Panel... design-time detail

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
A Ratcliffe - 13 Oct 2005 15:37 GMT
Hi

I'm working on a 2-way splitter for something I'm developing in C#... ok so
the MFC version wasn't amazing, but at least we had something to work with.
Anyway, given that it will always have 4 child panes, it should only ever
have 4 children - not 3 or 5 (or more).

I figure it would make sense to have the 4 'panes' show on the screen in
design time, and any control/panel that was dragged into one of the four
would fill it - thus preneting too many controls. If only 3 panes had been
filled, there would be a warning at run-time.

So basically, how is the best way to do this?

I know I can write the 2-way splitter directly into code, but given my
needs, I want it as a visual control I can work with at design-time.

Yours,

Ann-Marie
A Ratcliffe - 15 Oct 2005 07:36 GMT
Hi again.

Ok, I have a partial update, but still having some issues. I got round the
general problem (4 areas to drag into) by creating 4 Panel controls on my
control, and the user can drop into these (or will be able to, once I've
understood how to drop onto Panels on a custom control (there's a recent
news thread on it).

On to my problem, or maybe it's a design issue. Now I have 4 panels which
act as containers, and actually the added advantage that the designer will
be able to drop controls anywhere in each of the panels. However, if the
control's dropped into the panels need to fill them (as I'll be doing for
the current project where I need this), it seems a waste to have a panel
control whose only purpose is to hold another single control that covers it
entirely. I was just wondering if it's possible to just create the 4 Panels
at design-time... eg:-

At Design-time:

Splitter-control
  Pane[0] -> Panel(part of splitter/designer) ->
Panel(user-inserted)->[Controls]
  Pane[1] -> Panel(part of splitter/designer) -> User-Control
  Pane[2] -> Panel(part of splitter/designer) -> User-Control
  Pane[3] -> Panel(part of splitter/designer) ->[Controls]

At Run-time:

Splitter-control
  Pane[0] -> Panel(user-inserted)->[Controls]
  Pane[1] -> User-Control
  Pane[2] -> User-Control
  Pane[3] -> Panel(auto-created) ->[Controls]

As you can see, at runtime, the extraneous design-time panel is removed, and
only created at run-time if the pane doesn't contain a Fill-docked control.

Hope this makes sense, of am I digging myself into a hole here...

Yours,

Ann-Marie

> Hi
>
[quoted text clipped - 16 lines]
>
> Ann-Marie

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.