Group controls and move them together

Group controls and move them together

Postby concentra » Thu May 17, 2018 4:55 pm

Hi.

I it possible to group a set of controls and move them together on a dialog ?
Like defining a group of ( say + button + get ) and move them together on the dialog in only one command ?

Regards.

Maurício Faria
User avatar
concentra
 
Posts: 124
Joined: Mon Nov 14, 2005 10:15 am
Location: Brazil

Re: Group controls and move them together

Postby nageswaragunupudi » Fri May 18, 2018 10:06 pm

Yes. You need to create the Group control and other controls in the ON INIT clause.

Sample:
Code: Select all  Expand view
#include "fivewin.ch"

function Main()

   local oDlg, oGroup

   DEFINE DIALOG oDlg SIZE 700,400 PIXEL TRUEPIXEL
   ACTIVATE DIALOG oDlg CENTERED ON INIT DlgControls( oDlg )

return nil

function dlgcontrols( oDlg )

   local oGroup

   @ 20,20 SAY "First" SIZE 100,20 PIXEL OF oDlg

   @ 50,20 GROUP oGroup TO 150,170 PIXEL OF oDlg

   @ 10,10 BUTTON "OK" SIZE 60,20 PIXEL OF oGroup ;
      ACTION oGroup:Move( oGroup:nTop, oGroup:nLeft + 30, , , .t. )

   @ 40,10 SAY "Inside" SIZE 100,20 PIXEL OF oGroup

return nil
 
Regards

G. N. Rao.
Hyderabad, India
User avatar
nageswaragunupudi
 
Posts: 10620
Joined: Sun Nov 19, 2006 5:22 am
Location: India

Re: Group controls and move them together

Postby concentra » Thu May 24, 2018 10:23 am

Thanks.
User avatar
concentra
 
Posts: 124
Joined: Mon Nov 14, 2005 10:15 am
Location: Brazil


Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: No registered users and 40 guests