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

Problem adding Tab control to a form

Hi All,

I'm running MSDE 2002, ver. 7.0.9466 with Net Framework 1.0, ver. 1.0.3705
over Win2000ProSP4.

I created a new Visual C# project using the Windows Application template.

I'm trying to create a form (or dialog, I don't care which, for the moment)
which has a vertical splitter with the left half containing a few tabbed
pages and the right half a Rich Text Edit control.

I added a Panel and docked it to the left and added the TabControl to the
panel, along with a couple of tabs. I added a Splitter, which was generated
to right of the panel. I added the Rich Text Edit control to the right of
the splitter and gave it Fill docking.

That worked pretty well except that the tab control did not occupy the full
panel: it was docked to the lower right corner of the panel.

How can I correct this? Are there some patches I should be adding to my
configuration?

--
TIA,
Richard

640K ought to be enough for anybody.
Bill Gates, 1981
Nov 15 '05 #1
2 2141
Hi All,

I got one solution that seems to work. I commented out one generated code
line and substituted another as follows:
// this.tabControl1.Location = new System.Drawing.Point(80, 280); // RLM

this.tabControl1.Dock = System.Windows.Forms.DockStyle.Fill; // RLM

These changes were made in InitializeComponent, which should be proper,
right? That is, they shouldn't confuse the code generator nor get replaced
by future use of the GUI creation mechanism, right?
BTW, why wasn't the Dock property listed in the tabControl properties list?

Regards,
Richard

"Richard Muller" <Ri******************@comcast.net> wrote in message
news:eO**************@TK2MSFTNGP10.phx.gbl...
Hi All,

I'm running MSDE 2002, ver. 7.0.9466 with Net Framework 1.0, ver. 1.0.3705
over Win2000ProSP4.

I created a new Visual C# project using the Windows Application template.

I'm trying to create a form (or dialog, I don't care which, for the moment) which has a vertical splitter with the left half containing a few tabbed
pages and the right half a Rich Text Edit control.

I added a Panel and docked it to the left and added the TabControl to the
panel, along with a couple of tabs. I added a Splitter, which was generated to right of the panel. I added the Rich Text Edit control to the right of
the splitter and gave it Fill docking.

That worked pretty well except that the tab control did not occupy the full panel: it was docked to the lower right corner of the panel.

How can I correct this? Are there some patches I should be adding to my
configuration?

--
TIA,
Richard

640K ought to be enough for anybody.
Bill Gates, 1981

Nov 15 '05 #2
The Properties frame was too small, so I got fooled into thinking there was
only one or two properties. I just realized that and discovered, happily,
that there was a Dock property that I could have clicked, and which is set
to "Fill" as a consequence of my manual code changes. Oh well, live and
learn.
Nov 15 '05 #3

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

Similar topics

7
by: Mike | last post by:
Hi! I posted this question in browser_ctl group as well but got no results. I have a form with embedded WebBrowser. Upon clicking on a link in the embedded webbrowser that calls JavaScript's...
6
by: Robin Bonin | last post by:
In my user contol I am creating a set of dropdownlists. Each list is created based on input from the other lists. The problem I am having is setting the selected index on the lists. If someone...
3
by: Ankit Aneja | last post by:
I have a strange situation and I have no idea how to solve this. Its a Recruitment Search Page,in the Admin Page, for every button click event the Admin Person has to create a checkbox on the users...
10
by: Charles Law | last post by:
For some reason, when I click the X to close my MDI parent form, the action appears to be re-directed to one of the MDI child forms, and the parent remains open. I am then unable to close the...
0
by: Pawan Narula via DotNetMonster.com | last post by:
hi all, i'm using VB.NET and trying to code for contact management in a tree. all my contacts r saved in a text file and my C dll reads them one by one and sends to VB callback in a sync mode...
13
by: Lee Newson | last post by:
Hi, I have just written my first application using VB.NET. The app works fine when i am running it within .NET for debugging purposes, however when i try to run the app from the .exe file that...
7
by: Dino Buljubasic | last post by:
Hi, I am using C# 2.0 (VS2005) to build my user control that contains a number of dynamically loaded ListViews. ListViewItems have their ForeColor properties set to either black or blue to...
7
by: Trickynick1001 | last post by:
Hi, a newbie here. I don't have a real firm grasp on the idea of Javascript, as I'm used to programming in Qbasic and C. I'm not used to OOP. Anyway, I really don't have any idea what the...
3
by: Greg | last post by:
This works properly: 1. Create a new Form and set it's size to 229, 474. 2. Drag a Panel to the form and set the following properties: Size = 216, 438 Location = 3,1 Anchor = Top, Bottom...
9
by: Ecohouse | last post by:
I have a main form with two subforms. The first subform has the child link to the main form identity key. subform1 - Master Field: SK Child Field: TrainingMasterSK The second subform has a...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
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: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
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...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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...

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.