Recent

Author Topic: resize code  (Read 7486 times)

Lazarususer6789

  • New Member
  • *
  • Posts: 15
resize code
« on: April 29, 2010, 02:09:10 pm »
how do i make something resize with the window like a button or an Active x control same as the vb6 exe here http://ff24eva.0adz.com/vbp.7z :-[and how do i put Active X in the window :-[ i am new to  Lazarus but & i have no idea what to do :(

felipemdc

  • Administrator
  • Hero Member
  • *
  • Posts: 3538
Re: resize code
« Reply #1 on: May 03, 2010, 07:38:32 pm »
It's easy to resize the window, just use the Width and Height properties of the window, for example:

MyForm.Width := 500;
MyForm.Height := 200;

felipemdc

  • Administrator
  • Hero Member
  • *
  • Posts: 3538
Re: resize code
« Reply #2 on: May 03, 2010, 08:30:35 pm »
The simplest way is to create an OnResize event handler for the form and there add code to resize your components.

You can also study the following documentation to learn how to do this using LCL Properties:

http://wiki.lazarus.freepascal.org/Autosize_/_Layout

http://wiki.lazarus.freepascal.org/LCL_AutoSizing

Lazarususer6789

  • New Member
  • *
  • Posts: 15
Re: resize code
« Reply #3 on: May 04, 2010, 06:43:48 pm »
 :D Thank You

 

TinyPortal © 2005-2018