FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour Child dialog defined in .RC then redefine as Popup - SOLVED
Posts: 811
Joined: Tue May 06, 2008 04:28 AM
Child dialog defined in .RC then redefine as Popup - SOLVED
Posted: Sat Oct 18, 2014 03:56 AM

Hi All,

I have a child dialog defined in .RC as WS_CHILD.. it has 2 purpose, one for data entry as child and should be popup when viewing..

how to do it WS_POPUP when I redefine it?.... without using another window as parent..

Possible?

Kind Regards,

Frances



Fivewin for xHarbour v18.07

xHarbour v1.2.3.x

BCC 7.3 + PellesC8 ( Resource Compiler only)

ADS 10.1 / MariaDB

Crystal Reports 8.5/9.23 DE

xMate v1.15
Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Re: Child dialog defined in .RC then redefine as Popup
Posted: Sat Oct 18, 2014 12:47 PM

Frances,

Try changing its style from the ON INIT clause usign SetWindowLong( hWnd, GWL_STYLE, ... )

regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 811
Joined: Tue May 06, 2008 04:28 AM
Re: Child dialog defined in .RC then redefine as Popup
Posted: Mon Oct 20, 2014 05:28 AM

Antonio,

It didn't worked. :(

Kind Regards,

Frances



Fivewin for xHarbour v18.07

xHarbour v1.2.3.x

BCC 7.3 + PellesC8 ( Resource Compiler only)

ADS 10.1 / MariaDB

Crystal Reports 8.5/9.23 DE

xMate v1.15
Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Re: Child dialog defined in .RC then redefine as Popup
Posted: Mon Oct 20, 2014 06:06 AM

Frances,

Could you please show me your code for it ? thanks

regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 811
Joined: Tue May 06, 2008 04:28 AM
Re: Child dialog defined in .RC then redefine as Popup
Posted: Wed Oct 22, 2014 02:00 AM
Antonio,

I will finish a testbed program where I can collate and test my issues in FWH and post it here.

the dialog in .rc is like this
Code (fw): Select all Collapse
MY_DIALOG DIALOGEX 1,1,500,500
FONT 9,"Verdana",0,0,0
STYLE WS_CHILD
BEGIN
    //....
END


I use this MY_DIALOG to other container like FOLDEREX.. but I'd like to just pop it as dialog (without creating a Window container).
Kind Regards,

Frances



Fivewin for xHarbour v18.07

xHarbour v1.2.3.x

BCC 7.3 + PellesC8 ( Resource Compiler only)

ADS 10.1 / MariaDB

Crystal Reports 8.5/9.23 DE

xMate v1.15
Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Re: Child dialog defined in .RC then redefine as Popup
Posted: Wed Oct 22, 2014 09:49 AM

Frances,

Are you sure that you properly tested SetWindowLong( hWnd, GWL_STYLE, ... ) from the ON INIT clause ?

regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 811
Joined: Tue May 06, 2008 04:28 AM
Re: Child dialog defined in .RC then redefine as Popup
Posted: Wed Oct 22, 2014 11:50 PM
Antonio Linares wrote:Frances,

Are you sure that you properly tested SetWindowLong( hWnd, GWL_STYLE, ... ) from the ON INIT clause ?




Antonio,

Yes. I am very sure.

i'm posting here my testbed.. this will grow as I encounter issues in FWH.

Using xMate as project manager.

https://drive.google.com/folderview?id=0B3UHMYq8I6tHUTJyWnlTN3lQcEU&usp=drive_web


Please help. Counting on you.
If you have gmail account I can add you to edit if you like.

Thanks.
Kind Regards,

Frances



Fivewin for xHarbour v18.07

xHarbour v1.2.3.x

BCC 7.3 + PellesC8 ( Resource Compiler only)

ADS 10.1 / MariaDB

Crystal Reports 8.5/9.23 DE

xMate v1.15
Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Re: Child dialog defined in .RC then redefine as Popup
Posted: Thu Oct 23, 2014 05:46 AM
Frances,

Here this works fine :-)

Code (fw): Select all Collapse
PROCEDURE uDialog01b()

 LOCAL oDlg1, oDlg2
 LOCAL oGet, uVar := Space(10)

   DEFINE DIALOG oDlg1 RESOURCE 'MY_DIALOG'

   REDEFINE GROUP ID 1001 OF oDlg1 TRANSPARENT

   REDEFINE SAY ID 1002 OF oDlg1 TRANSPARENT

   REDEFINE GET oGet VAR uVar ID 1003 OF oDlg1

   ACTIVATE DIALOG oDlg1 NOWAIT ;
      ON INIT oDlg1:Hide()
      
   DEFINE DIALOG oDlg2
   
   ACTIVATE DIALOG oDlg2 ;
      ON INIT ( oDlg2:SetSize( oDlg1:nWidth, oDlg1:nHeight ),;
                oDlg2:Center(),;
                uChangeParent( oDlg1, oDlg2 ), oDlg1:End() )
   
RETURN
regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 811
Joined: Tue May 06, 2008 04:28 AM
Re: Child dialog defined in .RC then redefine as Popup
Posted: Thu Oct 23, 2014 07:31 AM

Antonio,

If that is the approach, the procedure uDialog01a() could be much better... ??

Kind Regards,

Frances



Fivewin for xHarbour v18.07

xHarbour v1.2.3.x

BCC 7.3 + PellesC8 ( Resource Compiler only)

ADS 10.1 / MariaDB

Crystal Reports 8.5/9.23 DE

xMate v1.15

Continue the discussion