Solved

Resizing Forms ...

Posted on 2000-04-17
5
194 Views
Last Modified: 2010-04-04
Hi there,

I need to show a form in my application whiwh can only be resized vertically.
I mean that only the 'height'-property can be changed (not the 'Width'-property)
Can someone help me out with this problem?

Thanx,

The Mayor

BTW, I'm using Delphi 5.
0
Comment
Question by:wimmeyvaert
5 Comments
 
LVL 6

Author Comment

by:wimmeyvaert
ID: 2722441
Hi,

Both Motaz and Epsylon offered me a good solution, but I prefer the solution Epsylon offered.

So, thanx to both !!


Best regards.
0
 
LVL 7

Expert Comment

by:Motaz
ID: 2722292
Write this code in your Form's OnCanResize event:

  if NewWidth <> Self.width then
    Resize:= False
  else
    Resize:= True;


Motaz
0
 
LVL 13

Accepted Solution

by:
Epsylon earned 50 total points
ID: 2722298
Hi,

you can use the contraints property:

  Constraints.MinWidth := 500;
  Constraints.MaxWidth := 500;

Not sure if this is what you want...

Regards,

Epsylon.
0
 
LVL 1

Expert Comment

by:tomer_engel
ID: 2722325
the constrainta propery is the best solution for this job...
0
 
LVL 7

Expert Comment

by:Motaz
ID: 2722605
:-(
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

In this tutorial I will show you how to use the Windows Speech API in Delphi. I will only cover basic functions such as text to speech and controlling the speed of the speech. SAPI Installation First you need to install the SAPI type library, th…
Hello everybody This Article will show you how to validate number with TEdit control, What's the TEdit control? TEdit is a standard Windows edit control on a form, it allows to user to write, read and copy/paste single line of text. Usua…
This video gives you a great overview about bandwidth monitoring with SNMP and WMI with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're looking for how to monitor bandwidth using netflow or packet s…
When you create an app prototype with Adobe XD, you can insert system screens -- sharing or Control Center, for example -- with just a few clicks. This video shows you how. You can take the full course on Experts Exchange at http://bit.ly/XDcourse.

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now