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

tiling windows

Hello,
I write application which displays 3 windows at the startup. Is there
any way (apart from hardcoding their location), to display them tiled (so
that they do not overlap)?

Thx

Piotrek Stachowicz
Nov 16 '05 #1
3 1377
You can do it by .NET tools only in MDI container.
If you have separate forms opened within regular enviroment you will need to
calculate their locations.
From the other habd you can prebuild screen bounds and set each one of you
windows StartPosition to WindowsDefaultBounds. Hope it'll help.

--
Tamir Khason
You want dot.NET? Just ask:
"Please, www.dotnet.us "
"Piotrek Stachowicz" <dy******@poczta.onet.pl> wrote in message
news:cb**********@news.onet.pl...
Hello,
I write application which displays 3 windows at the startup. Is there
any way (apart from hardcoding their location), to display them tiled (so
that they do not overlap)?

Thx

Piotrek Stachowicz

Nov 16 '05 #2
Hi,

you could get the screen size and then calculate the position from that
point.

Snippet:

For Window #1:

Rectangle workrect = Screen.PrimaryScreen.WorkingArea;
this->Height = workrect.Height /3;
For Window #2:

Rectangle workrect = Screen.PrimaryScreen.WorkingArea;
this.Height = workrect.Height /3;
Point ptTopLeft = new Point(0,this.Height);
this.Location = ptTopLeft;
For Window #3:

Rectangle workrect = Screen.PrimaryScreen.WorkingArea;
this.Height = workrect.Height /3;
Point ptTopLeft = new Point(0,2*this.Height);
this.Location = ptTopLeft;

This should solve your problem. I'm not sure whether all the calls are
correct, since I'm coding C++ at the moment, so I might get confused,
but this is basically the way to go.

Martin

Piotrek Stachowicz wrote:
Hello,
I write application which displays 3 windows at the startup. Is there
any way (apart from hardcoding their location), to display them tiled (so
that they do not overlap)?

Thx

Piotrek Stachowicz

Nov 16 '05 #3
Tamir,mphanke:
Gosh, people, you are fast :)
Thanks

Piotrek
Nov 16 '05 #4

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

Similar topics

2
by: Ken Lindner | last post by:
I have a need to become familiar with SQL Server 2000 for work. Needless to say I am new to SQL Server any version, but not IT in general. My employer has provided me with the SQL Server 2000...
0
by: Jim Hubbard | last post by:
By true tiling I do not mean the Vertical tiling or horizontal tiling like .... 1 2 3 4 or
8
by: Ron Holmes | last post by:
I want to place a background image on a windows form. Is there a way to prevent the image from Tiling without using an image box resized to the size of the form? I am using Visual Studio 2003...
1
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...
0
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 -...
1
by: Jim Hubbard | last post by:
By true tiling I don't mean the vertical or horizontal tiling that is normally though of like... 123 or 1 2 3
3
by: Sridhar | last post by:
Hi, I have created a user control which has the html code as follows <TABLE id="ToolBarTable" cellSpacing="0" cellPadding="0" width="100%" border="0"> <tr> <td align="right"...
3
by: Viken Karaguesian | last post by:
Hello all, I need somehelp with background tiling. I have a sneaking suspicion that what I want to do is not possible, but I'll ask anyway. :>) First some background: Here's the site in...
0
by: kirby.urner | last post by:
Probably a fault line or cultural divide between acutely differing schools of thought, is in this area of tiling or mosaic making. Some schools consider this a stupid waste of time, others a core...
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: 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...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
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
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
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

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.