how to set Parent to Control

Post Reply
User avatar
Jimmy
Posts: 1740
Joined: Thu Sep 05, 2019 5:32 am
Location: Hamburg, Germany
Has thanked: 2 times

how to set Parent to Control

Post by Jimmy »

hi,

i know Fivewin use OF Window ti assin Control

now i have this

Code: Select all | Expand

  DEFINE WINDOW oWnd FROM nTop, nLeft TO nHeight, nWidth PIXEL
      oExplorer := TExplorer():New( nTop, nLeft, nWidth - 20, nHeight -20, cPath )

how to set "Parent" oWnd to CLASS TExplorer() :idea:

if want to TABPAGE so i have to assign every Instance of TExplorer() to "Parent" TABPAGE
greeting,
Jimmy
User avatar
Enrico Maria Giordano
Posts: 8761
Joined: Thu Oct 06, 2005 8:17 pm
Location: Roma - Italia
Has thanked: 1 time
Been thanked: 5 times
Contact:

Re: how to set Parent to Control

Post by Enrico Maria Giordano »

Look at the fifth parameter:

Code: Select all | Expand

METHOD New( nTop, nLeft, nWidth, nHeight, oWnd, nClrFore, nClrBack, oBrush, ;
            l2007, l2010, l2013, l2015 ) CLASS TExplorerBar
User avatar
Jimmy
Posts: 1740
Joined: Thu Sep 05, 2019 5:32 am
Location: Hamburg, Germany
Has thanked: 2 times

Re: how to set Parent to Control

Post by Jimmy »

hi Enrico,
Enrico Maria Giordano wrote:Look at the fifth parameter:

ooh, YES oWnd

Code: Select all | Expand

DEFAULT oWnd := GetWndDefault()

so it is a Handle to point to Parent (not a Object)

thx for help
greeting,
Jimmy
User avatar
Jimmy
Posts: 1740
Joined: Thu Sep 05, 2019 5:32 am
Location: Hamburg, Germany
Has thanked: 2 times

Re: how to set Parent to Control

Post by Jimmy »

hi Enrico,
Enrico Maria Giordano wrote:No, it has to be an object.

uuups ... sorry YES you are right
greeting,
Jimmy
Post Reply