I noticed that the INIT clause doesn't assign .F. to lExit so I changed the code: METHOD Activate() CLASS TAlbum local hWndMain ::CreateWindow() ::CreateControls() ::SetVScroll() ...
José Luis, Add this new DATA in Class TAlbum: DATA lExit INIT .F. and modify this method this way: METHOD Activate() CLASS TAlbum ::CreateWindow() ::CreateControls() ::SetVScroll() ::oWnd:bResized := { ...
... "SAVE" SIZE 100,35 PIXEL OF oDlg FLAT WHEN oRec:Modified() ; ACTION ( oRec:City := dtos( date() ) + "/" + time() ,oRec:Save(), lExit := .t., oDlg:End() ) The customer numbers are one after the other but chronology is not guaranteed. Best regards Otto http://mybergland.com/FWForum/Clip6.jpg
the window remains opened because it belongs to the operating system, not to the PRG :-) Try this: local lExit := .F. ... ACTIVATE WINDOW oWnd StopUntil( { || lExit } ) From the window, change lExit to .T. to finally exit. Wwoooowwww ! And that is working ! :D Very fine ! So ...