473,387 Members | 1,541 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,387 software developers and data experts.

datagridview on a splitcontainer on a form

Hello,

Ive got a datagridview, on a splitcontainer, in a
system.windows.forms.usercontrol.

The datagrid view by default shows 3 colums of data and fills exactly
the size of the user control form.

This control is then called from another c# solution, and it displays
fine when called and shown.

My problem is that at some point a user has the option to display more
colums of data in the datagridview, and this causes the horizotal
scroll bard to appear and the columns are now off the edge of the
window and you need to scroll back and forwards to see it.

What i want is a way to make the parent usercontrol and form
autoresize wider when more columns are displayed in the datagrid view.
I then want the user control to auto shrink when the number of
displayed columns is reduced. In short i want the host usercontrol
/form to auto resize up and down to fit around the new size of the
displayed datagridview.

I have tried all the anchor/dock fill, auto resize options,
eliminating the horizontal scroll bar, but the hosting form never
resizes, the datagridview columns always disappear of the edge of the
window.

I am using vs 2005 c#, if anyone can help please or point me in the
right direction

thanks

Peted
Apr 3 '08 #1
0 2453

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

Similar topics

1
by: Martin | last post by:
Hi all! I made a UserControl with a SplitContainer in it. I put some controls in the SplitContainer.Panel1. After that, I created a new UserControl which inherit from the previously created...
7
by: newscorrespondent | last post by:
I want to save the state of a splitcontainer when an application ends. I also save the form state. The SplitContainer does not seem to have a well defined place to put intiialization and...
0
by: Ronald S. Cook | last post by:
Thanks in advance for reading/responding. In my Windows forms app, I was going to have an Infragistics ListBar control docking/filling the left panel of a SplitContainer, and use the right panel...
7
by: =?Utf-8?B?TG9zdEluTUQ=?= | last post by:
Hi All :) I'm converting VB6 using True DBGrid Pro 8.0 to VB2005 using DataGridView. True DBGrid has a MultipleLines property that controls whether individual records span multiple lines. Is...
2
by: Doc John | last post by:
We developed a Win application that basically consists of an Mdi Form and several child Forms. Now we want to change its appearance so that it has an Outlook-like appearance: it would have a panel...
1
by: Jeff Williams | last post by:
I have a form which contains a split panel In Panel 2 I have an OK and Cancel button at the bottom of the Panel. I add a form to the top of the panel so I now have a form with a fixed Ok and...
0
by: KalupaPaluku | last post by:
Hello!!! I've got a problem of my form application that the KeyDown function doesn't work. It suppose to be go to the next textbox field within same panel control but it doesn't work, as i'm using...
1
by: Zoliq | last post by:
Hi, I have the following problem: have a splitcontainer with horizontal orientation. The application saves the current settings of the user interface including the splitter distance when the form...
5
by: kulabhishek | last post by:
Hello, I have developed one user control using SplitContainer. It is simply like two textboxes connected to each other with splitter in between them. Whenever I increase width of the control ...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
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: 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...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
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
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...
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
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...

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.