Solved

Assigning values to form.constraints

Posted on 2001-08-07
2
140 Views
Last Modified: 2010-04-06
I currently have a minheight & minwidth value set to my main from in a program.

When a button is pressed I need to change these values, but I cant work out how to change the constraints in code.

Please can someone supply me with a coded example.

Thankyou.
0
Comment
Question by:chunky1
2 Comments
 
LVL 5

Accepted Solution

by:
alanwhincup earned 15 total points
ID: 6359902
Just do something like this:

procedure TForm1.Button1Click(Sender: TObject);
begin
  Form1.Constraints.MaxHeight := 300;
  Form1.Constraints.MaxWidth := 300;
  Form1.Constraints.MinHeight := 300;
  Form1.Constraints.MinWidth := 300;
end;
0
 
LVL 1

Author Comment

by:chunky1
ID: 6359946
Why wouldn't it accept that the first time ?

Obviously a bad day !

0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

A lot of questions regard threads in Delphi.   One of the more specific questions is how to show progress of the thread.   Updating a progressbar from inside a thread is a mistake. A solution to this would be to send a synchronized message to the…
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.

705 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

20 Experts available now in Live!

Get 1:1 Help Now