How to make a window modal to CTD

forum.cdk (1998-2005) & forum.td.cdk (2005-2010)
Thomas Lauzi

How to make a window modal to CTD

Post by Thomas Lauzi » 13 Aug 2002, 16:59

 Posted by:  Thomas Lauzi 

Hi,
i want to make a notification window, that stays in front of CTD and not
behind,
when i select something in the outline. I tried a little bit with the CDK
sample notify.app
to manage it. (when i call a function like SalBringWindowToTop, the focus is
in the window and not in the outline anymore)
How to achieve this ???

Thanks
Thomas L.

Catalin

Re: How to make a window modal to CTD

Post by Catalin » 27 Aug 2002, 15:27

 Posted by:  Catalin 

Hi,

Add $MainWindow as the second parameter of the notify tool and
then on the SAM_AppStartup use something like this:

Call SalCreateWindow( frmNotify,
lNumberToWindowHandle( SalStrToNumber( strArgArray[2] ) ),
Outline.m_hOutline )

Catalin

Jim McNamara

Re: How to make a window modal to CTD

Post by Jim McNamara » 27 Aug 2002, 15:36

 Posted by:  Jim McNamara 

Also you can set a dialogue property as 'Modeless' and use
SalCreateWindow( dlgNotify, hWndForm) and it will stay in front of it's
parent (hWndForm).

Thomas Lauzi

Re: How to make a window modal to CTD

Post by Thomas Lauzi » 27 Aug 2002, 16:22

 Posted by:  Thomas Lauzi 

Thanks, this was was i missed '$Mainwindow'
I´ll try it, soon.

Thomas L.

Thomas Lauzi

Re: How to make a window modal to CTD

Post by Thomas Lauzi » 27 Aug 2002, 16:25

 Posted by:  Thomas Lauzi 

Nope, this i tried and it failed, because the parent must be CTD, that a
dialog can stay in front of,
but hWndForm does not have the handle of CTD.I also tried to find CTD by its
title, but if you open the same apps twice
i get a problem.

Thomas L.

Frank Boettcher (ITG)

Re: How to make a window modal to CTD

Post by Frank Boettcher (ITG) » 27 Aug 2002, 16:33

 Posted by:  Frank \(ITG\) 

You can also use

hWndCTD = SalOutlineUIFrameOfOutline ( hOutline )

Regards,
Frank Boettcher
Ice Tea Group, LLC
www.iceteagroup.com

Return to “td.cdk”

Who is online

Users browsing this forum: No registered users and 0 guests