Focus error on this new project

Focus error on this new project

Postby Marc Venken » Thu Dec 09, 2021 10:10 am

For a new project, I was combining serveral new functions to have a nicer looking program.
I use as always some sample programs for starting things up.

There is also 'child' windows, so that could be it also, but I never used (MDI, Child),...

In this program I try to use :

Window, Dialog, ribbonbar, folderex and Xbrowse

The problem is that I use them wrong, because the mouse is not working on the xbrowse
I can not even click on a foldertab because they do nothing

If I comment out this on line 138 :
// oDlgRB[1]:nStyle := nOR(WS_CHILD) // ,WS_THICKFRAME

Then the xbrowse is floating, but the mouse is working ?

Probably there is also a fault in sequence of the window, ribbon, folderex and wbrowse setup ...

Can someone help me change the program in order to get this working ?

It should compile with in the samples folder and I used customers for testing

Code: Select all  Expand view  RUN

#include "fivewin.ch"
#include "inkey.ch"
#include "ribbon.ch"
#include 'xbrowse.ch'
#include "Directry.ch"
#include 'ord.ch'

REQUEST DBFCDX
REQUEST DBFFPT

#define MY_GREEN   nRGB( 145, 214, 124)
#define MY_LIGHTGREEN nRGB( 236, 255, 224)
#define MY_LIGHTYELLOW nRGB( 255, 251, 142)
#define MY_LIGHTBLUE nRGB( 214, 229, 255)
#define MY_PAARS nRGB( 232, 201, 255)
#define MY_YELLOW nRGB( 255, 220, 96)


STATIC oWnd
STATIC oDlgRB[3]

function main()

   local sys_versie := "Dec 2021 - 02/12"
   local cErrorLogFileName:= "MyLog.log"

   local oFol,oDlg
   local oRBar
   local oMenu, oMenuWnd, oBrush1
   local oGr, oGr1, oGr2, oGr3, oGr4
   LOCAL oSay1, oBmp, oFont1
   LOCAL oCursor

   Public oFld
   Public server_path := "\\CAROLIEN-PC\MARC\"
   Public local_path := "
c:\MARC\"

   Public cDrive := "
c:\marc\"                     // DEZE MOET
   Public cLocal := "
c:\marc\"                        // DEZE MOET
   Public lServer:=.F.


   SetPostErrorAction( { |cErrorLogFileName, oError| MyErrorAction( cErrorLogFileName, oError ) } )
   RDDSetDefault( "
DBFCDX" )

   set( 4, "
mm/dd/yyyy" )
   set( 5, 1930 )
   SET DATE BRITISH
   set deleted on
   SET EXCLUSIVE ON /// or off ?
   SET AUTORDER TO 1
   set exact on  //  juiste dingen vinden bij index exact match
   setkey( VK_F12,{|| Dbftonen() } )
   setkey( VK_F10,{|| popfiles() })

   //SET 3DLOOK ON

   xbrNumFormat( "
E", .t. )  // "E" for European, "A" for American and others // .t. for showing thousand separators

   menu oMenu 2007
   endmenu

   DEFINE FONT oFont1 NAME "
Arial" SIZE 0,-30 // BOLD

   DEFINE CURSOR oCursor HAND
   DEFINE BRUSH oBrush1 COLOR nRGB(223,233,244) // ,nRGB(255,255,255)
   DEFINE WINDOW oWnd TITLE "
Maveco Bedrijfskleding " + FWVERSION from 0,0 to 1030,1920 pixel MDI MENU oMenu brush oBrush1

   DEFINE RIBBONBAR oRBar WINDOW oWnd PROMPT "
Klanten", "Leveranciers", "Ingeven Documenten";
         HEIGHT 130 TOPMARGIN 25

   @ 145,05 FOLDEREX SIZE 1900,700 oFld PIXEL ROUND 5 ;
    PROMPT  "
Basis","Documenten","Personen","Facturen"
    oFld:aEnable = { .t.,.T.,.T.,.T. }

   oFld:aDialogs[1]:bGotfocus := { || msginfo("
Hier Folder") }


   ADD GROUP oGr  RIBBON oRBar TO OPTION 1 PROMPT "
Clipboard" width 130 BITMAP "..\bitmap\fivetech.BMP"

     @ 02, 05 ADD BUTTON oBtn2 GROUP oGr BITMAP "
bitmaps\cut16.BMP" ;
       SIZE 75, 20 PROMPT "
Dialog 01"  MOSTLEFT round ;
       action ( Dialog01() )

     @ 24, 05 ADD BUTTON oBtn3 GROUP oGr BITMAP "
bitmaps\copy16.BMP" ;
       SIZE 75, 20 PROMPT "
Dialog 02"  MOSTLEFT round ;
       action( Dialog02() )

     @ 46, 05 ADD BUTTON oBtn4 GROUP oGr BITMAP "
bitmaps\paste16.BMP" ;
       SIZE 75, 20 PROMPT "
Dialog 03"  MOSTLEFT round ;
       action( Dialog03() )

   ADD GROUP oGr2 RIBBON oRBar TO OPTION 1 PROMPT "
Exit" width 70 BITMAP "bitmap\fivetech.bmp"

     @ 15, 20 ADD BUTTON oBtn4 GROUP oGr2 BITMAP "
bitmaps\32x32\quit.BMP" ;
           SIZE 34,52 PROMPT "
Exit" action( oWnd:End())

   SET MESSAGE OF oWnd TO "
Version : "+sys_versie ;
      CENTERED CLOCK KEYBOARD 2007

   WndCenter(oWnd:hWnd)

   ACTIVATE WINDOW oWnd ON INIT Dialog01() MAXIMIZED
   //ACTIVATE WINDOW oWnd ON INIT oFld:dialog[1] MAXIMIZED
   //ACTIVATE WINDOW oWnd MAXIMIZED

   oRBar:End()

return nil




Procedure Dialog01()
   LOCAL aCoords:=GetCoors(oWnd:oWndClient), oBrush, oGet
   LOCAL sys_klant := space(10), nWild:=1
   LOCAL oFont1, oBmpAlpha
   LOCAL lEscapa:=.F.
   LOCAL oBrw[1], aVelden:={}, cCol
   LOCAL hBmp := ReadBitmap( 0, "
bitmaps\search.bmp" ) // the basic gradient bmp

//   netopen("
customer","last")
   use customer shared NEW

   HideDlg( 1 )

   if ValType(oDlgRB[1]) <> "
O"
      DEFINE FONT oFont1 NAME "
Ms Sans Serif" SIZE 0,-8 BOLD
      DEFINE FONT oBold NAME 'CALIBRI' SIZE 0,-12 BOLD
      DEFINE FONT oFont NAME "
CALIBRI" SIZE 0,-14
      DEFINE FONT oFont3 NAME "
Segoe UI" SIZE 0,-12
      DEFINE FONT oFontS NAME "
Segoe UI" SIZE 0,-09
      DEFINE FONT oFontXS NAME "
Segoe UI" SIZE 0,-08
      DEFINE BRUSH oBrush FILE "
Bitmaps\BackGrnd\Stone.bmp"
      //DEFINE DIALOG oDlgRB[1] FROM 0,0 TO 538,782 OF oWnd:oWndClient PIXEL // COLORS RGB(0,0,0),RGB(255,255,255)

      DEFINE DIALOG oDlgRB[1] FROM 0,0 TO 700,1900 OF oFld:aDialogs[1] PIXEL COLORS RGB(0,0,0),RGB(255,255,255)

      oDlgRB[1]:nStyle := nOR(WS_CHILD) // ,WS_THICKFRAME
      //oDlgRB[1]:oBrush := oBrush
      //oDlgRB[1]:lTransparent := .T.

   aVelden :=  { ;
   { "
ID"       , "ID"    ,nil,  90 }, ;
   { "
First"    , "First"   ,nil,  350 }, ;
   { "
Last"     , "Last"    ,nil, 300 }, ;
   { "
Street"   , "Street"  ,nil, 300 }, ;
   { "
City"     , "City"  ,nil, 200 }, ;
   { "
Zip"      , "Zip"   ,nil, 150 }}


   @ 0,0 XBROWSE oBrw[1] size -05,-20 PIXEL OF oDlgRB[1] font oFont ;
      DATASOURCE "
customer" ;
      COLUMNS aVelden ;
      AUTOSORT CELL LINES NOBORDER FOOTERS

   oBrw[1]:SetChecks()
   oBrw[1]:nStretchCol         := STRETCHCOL_WIDEST

   oBrw[1]:lHScroll := .F.
   oBrw[1]:nHeadStrAligns  := AL_CENTER

   for each cCol in { "
First","Last","Street"}
      WITH OBJECT oBrw[1]:oCol( cCol )
         :nEditType     := EDIT_GET
         :bClrHeader    := { || { CLR_GREEN, 155 } }
      END
   next
    //  Search GETBAR
   oBrw[1]:lGetBar   := .T.
   for each cCol in { "
First","Last","Street","City","Zip"}

      WITH OBJECT oBrw[1]:oCol( cCol )
       :uBarGetVal    := uValBlank( :Value )
       :cBarGetPic    := :cEditPicture
       :bClrEdit      := { || { CLR_BLACK, MY_LIGHTYELLOW }}

       :lBarGetOnKey := .t. // after having setfocus the oBrowse object, the end user can insert the characters directly into the get
       :cBarGetBmp := hBmp // this for show the Bitmap on the get
       :bBarGetAction := { || ( oBrw[1]:cAlias )->( SetFilter( oBrw[1] )) } // this for show the bitmap on the get and associated a action
       //:bBarGetChange := { |k,f,o| msginfo("
Enter") }
      END
   next

   WITH OBJECT oBrw[1]

      :lColChangeNotify := .t.
      :lFooter          := .t.
      :bRecSelHeader    := { || "
Klant" }
      :bRecSelData      := { |o| o:KeyNo }
      :bRecSelFooter    := { |o| o:nLen }
      :oRecSelFont      := oFont3  // optional
      :nRecSelWidth     := "
99999" // required size
      :lHScroll      := .f.
      :lMultiSelect     := .T.

      :bLDClickDatas := { || msginfo("
Enter")  }

      :nColDividerStyle := LINESTYLE_LIGHTGRAY
      :nRowDividerStyle := LINESTYLE_LIGHTGRAY
      :bClrRowFocus     := { || { CLR_BLACK, RGB(185,220,255) } }
      :nMarqueeStyle    := MARQSTYLE_HIGHLROWMS


      :bClrSelFocus = {|| { CLR_WHITE, RGB(0, 128, 128) } } // CUANDO TIENE EL FOCUS

      :oHeaderFonts     := oBold

         :bKeyDown   := { |k| if (K == VK_DELETE, Del_row(oBrw[1]),nil ) }


   END

   oBrw[1]:CreateFromCode()
   oBrw[1]:setfocus()

   ACTIVATE DIALOG oDlgRB[1] NOWAIT ; //CENTERED
          ON INIT (oDlgRB[1]:Move(aCoords[1]+0,aCoords[2]+0,,,.T.));
          VALID lEscapa

   else
      oDlgRB[1]:Show()
   endif

Return



Procedure Dialog02()
   LOCAL aCoords:=GetCoors(oWnd:oWndClient), oBrush, oGet, cTxtGet:="
Get in Dialog 02"
   LOCAL oFont1, oBmpAlpha
   LOCAL lEscapa:=.F.

   HideDlg( 2 )

   if ValType(oDlgRB[2]) <> "
O"
      oBmpAlpha:=TImage():Define(, "
..\Bitmaps\AlphaBmp\World.bmp" )
      DEFINE FONT oFont1 NAME "
Ms Sans Serif" SIZE 0,-8 BOLD
      DEFINE BRUSH oBrush FILE "
..\Bitmaps\BackGrnd\Stone.bmp"
      DEFINE DIALOG oDlgRB[2] FROM 0,0 TO 538,782 OF oWnd:oWndClient PIXEL // COLORS RGB(0,0,0),RGB(255,255,255)
         oDlgRB[2]:nStyle := nOR(WS_CHILD) // ,WS_THICKFRAME
         oDlgRB[2]:oBrush := oBrush
         oDlgRB[2]:lTransparent := .T.

         @ 30,30 SAY "
Some text bla bla bla in DIALOG 02" OF oDlgRB[2] PIXEL COLOR nRGB(0,0,125) FONT oFont1

         @ 45,30 GET oGet VAR cTxtGet OF oDlgRB[2] PIXEL

      ACTIVATE DIALOG oDlgRB[2] NOWAIT ; //CENTERED
          ON INIT (oDlgRB[2]:Move(aCoords[1]+0,aCoords[2]+0,,,.T.));
          ON PAINT (ABPaint( hDC,365,230, oBmpAlpha:hBitmap, 255 ));
          VALID lEscapa
   else
      oDlgRB[2]:Show()
   endif
Return




Procedure Dialog03()
   LOCAL aCoords:=GetCoors(oWnd:oWndClient), oBrush, oGet, cTxtGet:="
Get in Dialog 03"
   LOCAL oFont1, oBmpAlpha
   LOCAL lEscapa:=.F.

   HideDlg( 3 )

   if ValType(oDlgRB[3]) <> "
O"
      oBmpAlpha:=TImage():Define(, "
..\Bitmaps\AlphaBmp\World.bmp" )
      DEFINE FONT oFont1 NAME "
Ms Sans Serif" SIZE 0,-8 BOLD
      DEFINE BRUSH oBrush FILE "
..\Bitmaps\BackGrnd\Stone.bmp"
      DEFINE DIALOG oDlgRB[3] FROM 0,0 TO 538,782 OF oWnd:oWndClient PIXEL // COLORS RGB(0,0,0),RGB(255,255,255)
         oDlgRB[3]:nStyle := nOR(WS_CHILD) // ,WS_THICKFRAME
         oDlgRB[3]:oBrush := oBrush
         oDlgRB[3]:lTransparent := .T.

         @ 40,40 SAY "
Some text bla bla bla in DIALOG 03" OF oDlgRB[3] PIXEL COLOR nRGB(0,0,125) FONT oFont1

         @ 45,40 GET oGet VAR cTxtGet OF oDlgRB[3] PIXEL

      ACTIVATE DIALOG oDlgRB[3] NOWAIT ; //CENTERED
          ON INIT (oDlgRB[3]:Move(aCoords[1]+0,aCoords[2]+0,,,.T.));
          ON PAINT (ABPaint( hDC,395,260, oBmpAlpha:hBitmap, 255 ));
          VALID lEscapa
   else
      oDlgRB[3]:Show()
   endif
Return




Procedure HideDlg( nDlg )
   LOCAL i:=1
   for i:=1 TO Len(oDlgRB)
       if ValType(oDlgRB[i])=="
O"
          oDlgRB[i]:Hide()
       endif
   next
Return

function MyErrorAction( cErrorLogFileName, oError )
    LOCAL cErrScreen:="
"
    msginfo("
Er is een fout opgetreden in het programma.  Gelieve het programma opnieuw te starten")

return NIL

function lookup_klant(cKlant)
  msginfo(cKlant)
return NIL

Function dbftonen()
   local cErrorlog:="
"
   cErrorLog += CRLF + "
DataBases in use" + CRLF + "================" + CRLF
   for n = 1 to 255
      if ! Empty( Alias( n ) )
         cErrorLog += CRLF + Str( n, 3 ) + "
: " + If( Select() == n,"=> ", "   " ) + ;
                      (Alias(n))->( DbInfo( DBI_FULLPATH ) ) + Space( 2 ) + "
RddName: " + ;
                      ( Alias( n ) )->( RddName() ) + CRLF
         cErrorLog += "
    =======================================================" + CRLF
         cErrorLog += "
    RecNo    RecCount    BOF   EOF" + CRLF
         cErrorLog += "
  " + Transform( ( Alias( n ) )->( RecNo() ), "9999999" ) + ;
                      "
    " + Transform( ( Alias( n ) )->( RecCount() ), "9999999" ) + ;
                      "
   " + cValToChar( ( Alias( n ) )->( BoF() ) ) + ;
                      "
  " + cValToChar( ( Alias( n ) )->( EoF() ) ) + Transform( ( Alias( n ) )->( ordkeycount() ), "9999999" )  + CRLF + CRLF

         if ( Alias( n ) )->( RddName() ) != "
ARRAYRDD"
            cErrorLog += "
    Indexes in use " + Space( 23 ) + "TagName" + CRLF + CRLF
            for j = 1 to 25
               if ! Empty( ( Alias( n ) )->( IndexKey( j ) ) )
                  cErrorLog += Space( 8 ) + ;
                               If( ( Alias( n ) )->( IndexOrd() ) == j, "
=> ", "   " ) + ;
                               PadR( ( Alias( n ) )->( IndexKey( j ) ), 35 ) + ;
                               ( Alias( n ) )->( OrdName( j ) ) + ;
                               CRLF
               endif
            next
            cErrorLog += CRLF + "
    Relations in use" + CRLF + CRLF
            for j = 1 to 8
               if ! Empty( ( nTarget := ( Alias( n ) )->( DbRSelect( j ) ) ) )
                  cErrorLog += Space( 3 ) + Str( j ) + "
: " + ;
                               "
TO " + ( Alias( n ) )->( DbRelation( j ) ) + ;
                               "
INTO " + Alias( nTarget ) + CRLF
                  // uValue = ( Alias( n ) )->( DbRelation( j ) )
                  // cErrorLog += cValToChar( ordsetfocus( uValue ) ) + CRLF
               endif
            next

         endif
      endif
   next
   //msginfo(cErrorlog)
  // MemoEdit( @cText, [ctitle], [nTop], [nLeft], [nBottom], [nRight], [lRTF] ) --> lEdited.
   MemoEdit( @cErrorlog,"
Geopende Databases",10,60,60,150)

return NIL

function Popfiles()

   SET 3DLOOK ON

   DEFINE BRUSH oBrush STYLE TILED       // FiveWin new predefined Brushes
   DEFINE FONT oBold NAME 'CALIBRI' SIZE 0,-12 BOLD
   DEFINE FONT oFont NAME "
CALIBRI" SIZE 0,-14
   DEFINE FONT oFontBig NAME "
CALIBRI" SIZE 0,-24

   DEFINE DIALOG oDlgpop SIZE 200,100 PIXEL TRUEPIXEL ;
   TITLE "
Klantenbestand : ";
   GRADIENT { { 1, nRGB( 125, 155, 175 ), nRGB( 125, 155, 175 ) } }

   DEFINE BUTTONBAR oBar OF oDlgpop SIZE 45,45 2007

   DEFINE BUTTON oBtnSave OF oBar FILE "
bitmaps\save.bmp" PROMPT "Data"  GROUP TOOLTIP "Gegevens" ;
     ACTION popopenfile()
   DEFINE BUTTON OF oBar FILE "
bitmaps\print.bmp" PROMPT "Struct" TOOLTIP "Structure" ;
     ACTION popopenstruc()


   ACTIVATE DIALOG oDlgpop

return

function popopenfile()
   local oBrw
   if ! Empty( cFile := cGetFile(   "
DataFile (*.DBF)|*.dbf|",          ;
                                    "
Select Data File to Browse",1,     ;
                                    "
\programmas\fotoselect" ) )
      use &cFile alias datastruc NEW
      aStruc := DBSTRUCT()
      xbrowser("
datastruc") SHOW RECID FASTEDIT AUTOSORT ;
      SETUP (oBrw:lIncrFilter := .t.,oBrw:lSeekWild := .t. )
      close datastruc
   endif
return NIL
function popopenstruc()
   local cFile
   LOCAL aStruc

   if ! Empty( cFile := cGetFile(   "
DataFile (*.DBF)|*.dbf|",          ;
                                    "
Select Data File to Browse",1,     ;
                                    "
\programmas\fotoselect" ) )
      //use &cFile alias STRUC NEW shared
      use &cFile alias DATASTRUC NEW shared

      aStruc := datastruc->(DBSTRUCT())
      xbrowser(aStruc)
      close datastruc
   endif
return NIL

FUNCTION NETOPEN( cFile, cIndex, lMode, cAlias, nSeconds, lNewArea,cDriver, lReadOnly )
local nWaitTime, lContinue := .t., lSuccess  := .f., TSEL      := 0
DEFAULT lMode     :=  .T.                     // shared mode
DEFAULT cIndex :="
"
DEFAULT nSeconds  :=  3
DEFAULT cAlias    := cFile
DEFAULT lNewArea  :=  .t.
//DEFAULT cDriver   := "
COMIX"
DEFAULT cDriver   := "
DBFCDX"
//DEFAULT cDriver   := "
DBFNTX"
DEFAULT lReadOnly :=  .f.
nWaitTime := nSeconds
//cFile = cDrive+cFile
cFile = alltrim(cFile)+"
.dbf"
if lServer
  cFile = server_path + cFile
else
  cFile = local_path + cFile

endif

// Hier mag/moet eerst controle op //server// en dan eventueel de vraag stellen indien geen server aanwezig
//  Netopen ( cFile, lServer, cIndex,...)

// bestand het bestand
IF ! FILE( cFile )
   Exit("
Bestand " + CFILE + ".DBF is afwezig")
ENDIF
// verify driver is valid
if ascan( RddList(), cDriver ) == 0
   MSGSTOP("
Driver " + Cdriver + "  afwezig")
   Exit()
endif
//
// Indien reeds geopend, alles ok, select waar
//
IF SELECT(cAlias) # 0
   MsgInfo("
File : "+cAlias+" is reeds geopend")
   TSEL := SELECT(cAlias)
   SELECT(TSEL)
   lContinue := .t.
   lNewArea  := .f.
ENDIF
// while continuing to attempt open
Do while lContinue // while .not. timed-out
   while nSeconds > 0 .and. lContinue
     //dbUseArea( lNewArea, cDriver, cFile, cAlias, ( .not. lMode ), lReadOnly )
     dbUseArea( lNewArea, cDriver, cFile, cAlias, lMode, lReadOnly )
     // check for success/failure
     IF neterr()
       nSeconds--
       lSuccess  := .F.
      else
       // open successful
       nSeconds  := 0
       lSuccess  := .t.
       lContinue := .f.
     ENDIF
  ENDDO
  IF ! lSuccess
      nSeconds  := nWaitTime
      MSGSTOP("
Bestand " + CFILE+" Alias : "+cAlias + " is geopend door een andere gebruiker" + CRLF + CRLF + "Gelieve even te wachten")
      lSuccess   := .F.
      lContinue  := .T.
      lNewArea   := .T.
  ENDIF
  if !empty(cIndex)
    &cAlias->(dbsetorder(cIndex))
  endif

ENDDO

return lSuccess

CLASS TSeek STATIC

   DATA oBrw

   METHOD New( oBrw ) CONSTRUCTOR
   METHOD SetText( c ) INLINE ::oBrw:RefreshFooters()

ENDCLASS

METHOD New( oBrw ) CLASS TSeek

   ::oBrw   := oBrw

return Self

function del_row(oBrw)
  if MsgYesNo("
Deze regel wissen")
     oBrw:delete()
  endif
return

Function Exit(cErrInfo)
   cErrInfo+= CRLF + "
Gelieve deze fout te melden"+ CRLF + CRLF + "Het Programma zal nu eindigen"
   close all
   MSGSTOP(cErrInfo)
   SET RESOURCES TO
   ErrorLevel( 1 )
   QUIT
return NIL

static function SetFilter( oBrw )

   local cFilter := "
"
   local n, oCol, uVal, cType

   for n := 1 to Len( oBrw:aCols )
      oCol  := oBrw:aCols[ n ]
      if ! Empty( uVal := oCol:uBarGetVal )
         if !Empty( cFilter )
            cFilter  += "
.AND. "
         endif
         cType    := ValType( uVal )

         do case
         case cType == 'C'
            uVal     := Upper( AllTrim( uVal ) )
//            cFilter += '"
' + uVal + '" $ UPPER( ' + FieldName( n ) + " )"
            cFilter += '"
' + uVal + '" $ UPPER( ' + oCol:CExpr + " )"
         otherwise
//            cFilter  += FieldName( n ) + "
== " + cValToChar( uVal )
            cFilter  += oCol:cExpr + "
== " + cValToChar( uVal )
         endcase
      endif

   next
   *******************************
   */
   //msginfo(cFilter)
   //msgGet( "
title", "message", @cFilter )

   if Empty( cFilter )
      if ! Empty( DBFILTER() )
         DBCLEARFILTER()
         oBrw:Refresh()
      endif
   else
      if !( DBFILTER() == cFilter )
         SET FILTER TO &cFilter
         GO TOP
         oBrw:Refresh()
      endif
   endif

   oBrw:SetFocus()

return nil

Last edited by Marc Venken on Thu Dec 09, 2021 12:46 pm, edited 1 time in total.
Marc Venken
Using: FWH 23.04 with Harbour
User avatar
Marc Venken
 
Posts: 1456
Joined: Tue Jun 14, 2016 7:51 am
Location: Belgium

Re: Focus error on this new project

Postby karinha » Thu Dec 09, 2021 11:53 am

Translate please:

https://imgur.com/4mMIdfx

Image

Regards, saludos.
João Santos - São Paulo - Brasil - Phone: +55(11)95150-7341
User avatar
karinha
 
Posts: 7872
Joined: Tue Dec 20, 2005 7:36 pm
Location: São Paulo - Brasil

Re: Focus error on this new project

Postby Marc Venken » Thu Dec 09, 2021 12:45 pm

I used a netopen function to open the database
and the location of the path was set to c:\marc

I removed the netopen function with

use customer shared NEW

The error will go away than... Sorry
Marc Venken
Using: FWH 23.04 with Harbour
User avatar
Marc Venken
 
Posts: 1456
Joined: Tue Jun 14, 2016 7:51 am
Location: Belgium

Re: Focus error on this new project

Postby karinha » Thu Dec 09, 2021 12:54 pm

YES!! More or less. hahahaha.

https://imgur.com/OCOE9l0

Image

Regards, saludos.
João Santos - São Paulo - Brasil - Phone: +55(11)95150-7341
User avatar
karinha
 
Posts: 7872
Joined: Tue Dec 20, 2005 7:36 pm
Location: São Paulo - Brasil

Re: Focus error on this new project

Postby karinha » Thu Dec 09, 2021 1:35 pm

Marc, continue, please... Report errors. Thanks.

Code: Select all  Expand view  RUN

// \SAMPLES\MARC2.PRG  - 09/12/2021 - Modified by: Joao

#include "fivewin.ch"
#include "Directry.ch"
#include "inkey.ch"
#include 'ord.ch'
#include "ribbon.ch"
#include 'xbrowse.ch'

#define MY_GREEN   nRGB( 145, 214, 124)
#define MY_LIGHTGREEN nRGB( 236, 255, 224)
#define MY_LIGHTYELLOW nRGB( 255, 251, 142)
#define MY_LIGHTBLUE nRGB( 214, 229, 255)
#define MY_PAARS nRGB( 232, 201, 255)
#define MY_YELLOW nRGB( 255, 220, 96)

ANNOUNCE RDDSYS
REQUEST OrdKeyNo, OrdKeyCount, OrdCreate, OrdKeyGoto
REQUEST DBFCDX, DBFFPT

STATIC oWnd
STATIC oDlgRB[ 3 ]
STATIC SERVER_PATH, LOCAL_PATH, oFld, CDRIVE, cLocal
STATIC lServer := .F.

FUNCTION Main()

   LOCAL sys_versie := "Dec 2021 - 02/12"
   LOCAL cErrorLogFileName := "MyLog.log"
   LOCAL oFol, oDlg, oRBar, oMenu, oMenuWnd, oBrush1, oGr, oGr1, oGr2, oGr3, ;
         oGr4, oSay1, oBmp, oFont1, oCursor, oBtn2, oBtn3, oBtn4
   LOCAL aBitmaps := { "..\bitmaps\alphabmp\facebook.bmp",;
                       "..\bitmaps\alphabmp\windows.bmp",;
                       "..\bitmaps\alphabmp\game.bmp",;
                       "..\bitmaps\alphabmp\viddler.bmp",;
                       "..\bitmaps\alphabmp\mail.bmp",;
                       "..\bitmaps\alphabmp\call.bmp",;
                       "..\bitmaps\alphabmp\settings2.bmp",;
                       "..\bitmaps\alphabmp\exit.bmp" }

   RDDSETDEFAULT("DBFCDX")

   SET CENTURY ON
   SET DATE BRITISH
   SET TIME FORMAT TO "HH:MM:SS"
   SET EPOCH TO YEAR( DATE() ) - 30
   SET SOFTSEEK OFF
   SET WRAP ON
   SETCANCEL( .F. )
   SET CONFIRM OFF
   SET DELETED ON
   SET _3DLOOK ON
   SET UNIQUE OFF
   SET ESCAPE OFF
   SET EXACT ON
   SET EXCLUSIVE OFF
   SET MULTIPLE OFF

   SERVER_PATH := "\\CAROLIEN-PC\MARC\"
   LOCAL_PATH  := CURDRIVE()+"
:\MARC\"
   cDrive      := "
C:\MARC\"                     // DEZE MOET
   cLocal      := "
C:\MARC\"                     // DEZE MOET

   If .NOT. lIsDir( LOCAL_PATH )

      LMkdir( LOCAL_PATH )

   Endif

   FW_SetUnicode( .T. )

   SetBalloon( .T. ) // Balloon shape required for tooltips

   SkinButtons()

   SetGetColorFocus( CLR_GREEN )

   SETKEY( VK_F10, { | nKey | PROFILES() } )
   SETKEY( VK_F12, { | nKey | DBFTONEN() } ) //??

   xbrNumFormat( "
E", .T. )  // "E" for European, "A" for American and others // .t. for showing thousand separators

   MENU oMenu 2007
      // ??
   ENDMENU

   DEFINE FONT oFont1 NAME "
Arial" SIZE 0, - 30 // BOLD

   DEFINE CURSOR oCursor HAND
   DEFINE BRUSH oBrush1 COLOR nRGB( 223, 233, 244 )

   DEFINE WINDOW oWnd TITLE "
Maveco Bedrijfskleding " + FWVERSION ;
      FROM 0, 0 TO 1030, 1920 pixel MDI MENU oMenu BRUSH oBrush1

   DEFINE RIBBONBAR oRBar WINDOW oWnd PROMPT "
Klanten", "Leveranciers", "Ingeven Documenten";
      HEIGHT 130 TOPMARGIN 25

   @ 145, 05 FOLDEREX SIZE 1900, 700 oFld PIXEL ROUND 5                      ;
      PROMPT "
Basis", "Documenten", "Personen", "Facturen"                   ;
      BITMAPS aBitmaps                                                       ;
      TAB HEIGHT 25 FONT oFont1 COLOR CLR_CYAN TOP

   oFld:aEnable = { .T., .T., .T., .T., .F. }
   oFld:SetOption( 1 )
   oFld:aEnable = { .T., .T., .T., .T., .F. }
   oFld:Show()

   // action en el primero folder.
   Dialog01()

   // ??
   // oFld:aDialogs[ 1 ]:bGotfocus := {|| msginfo( "
Hier Folder" ) }

   ADD GROUP oGr  RIBBON oRBar TO OPTION 1 PROMPT "
Clipboard" width 130 ;
      BITMAP "
..\bitmap\fivetech.BMP"

   @ 02, 05 ADD BUTTON oBtn2 GROUP oGr BITMAP "
bitmaps\cut16.BMP" ;
      SIZE 75, 20 PROMPT "
Dialog 01"  MOSTLEFT round ;
      action ( Dialog01() )

   @ 24, 05 ADD BUTTON oBtn3 GROUP oGr BITMAP "
bitmaps\copy16.BMP" ;
      SIZE 75, 20 PROMPT "
Dialog 02"  MOSTLEFT round ;
      action( Dialog02() )

   @ 46, 05 ADD BUTTON oBtn4 GROUP oGr BITMAP "
bitmaps\paste16.BMP" ;
      SIZE 75, 20 PROMPT "
Dialog 03"  MOSTLEFT round ;
      action( Dialog03() )

   ADD GROUP oGr2 RIBBON oRBar TO OPTION 1 PROMPT "
Exit" width 70 ;
      BITMAP "
bitmap\fivetech.bmp"

   @ 15, 20 ADD BUTTON oBtn4 GROUP oGr2 BITMAP "
bitmaps\32x32\quit.BMP" ;
      SIZE 34, 52 PROMPT "
Exit" action( oWnd:End() )

   SET MESSAGE OF oWnd TO "
Version : " + sys_versie ;
      CENTERED CLOCK KEYBOARD 2007

   WndCenter( oWnd:hWnd )

   ACTIVATE WINDOW oWnd MAXIMIZED

   oBrush1:End()
   oRBar:End()

RETURN NIL

FUNCTION Dialog01()

   LOCAL oFont1, oBold, oFont, oFont3, oFontS, oFontXS
   LOCAL aCoords := GetCoors( oWnd:oWndClient ), oBrush, oGet
   LOCAL sys_klant := Space( 10 ), nWild := 1
   LOCAL oBmpAlpha
   LOCAL lEscapa := .F.
   LOCAL oBrw[ 1 ], aVelden := {}, cCol
   LOCAL hBmp := ReadBitmap( 0, "
bitmaps\search.bmp" )

   netopen( "
customer", "last" )

   HideDlg( 1 )

   IF ValType( oDlgRB[ 1 ] ) <> "
O"

      DEFINE FONT oFont1 NAME "
Ms Sans Serif" SIZE 0, - 8 BOLD
      DEFINE FONT oBold NAME 'CALIBRI' SIZE 0, - 12 BOLD
      DEFINE FONT oFont NAME "
CALIBRI" SIZE 0, - 14
      DEFINE FONT oFont3 NAME "
Segoe UI" SIZE 0, - 12
      DEFINE FONT oFontS NAME "
Segoe UI" SIZE 0, - 09
      DEFINE FONT oFontXS NAME "
Segoe UI" SIZE 0, - 08

      DEFINE BRUSH oBrush FILE "
Bitmaps\BackGrnd\Stone.bmp"

      DEFINE DIALOG oDlgRB[ 1 ] FROM 0, 0 TO 700, 1900 OF oFld:aDialogs[ 1 ] PIXEL COLORS RGB( 0, 0, 0 ), RGB( 255, 255, 255 )

      oDlgRB[ 1 ]:nStyle := nOR( WS_CHILD ) // ,WS_THICKFRAME

      aVelden :=  { ;
         { "
ID", "ID", NIL,  90 }, ;
         { "
First", "First", NIL,  350 }, ;
         { "
Last", "Last", NIL, 300 }, ;
         { "
Street", "Street", NIL, 300 }, ;
         { "
City", "City", NIL, 200 }, ;
         { "
Zip", "Zip", NIL, 150 } }

      @ 0, 0 XBROWSE oBrw[ 1 ] size - 05, - 20 PIXEL OF oDlgRB[ 1 ] font oFont ;
         DATASOURCE "
customer" ;
         COLUMNS aVelden ;
         AUTOSORT CELL LINES NOBORDER FOOTERS

      oBrw[ 1 ]:SetChecks()
      oBrw[ 1 ]:nStretchCol         := STRETCHCOL_WIDEST

      oBrw[ 1 ]:lHScroll := .F.
      oBrw[ 1 ]:nHeadStrAligns  := AL_CENTER

      FOR EACH cCol in { "
First", "Last", "Street" }
         WITH OBJECT oBrw[ 1 ]:oCol( cCol )
            :nEditType     := EDIT_GET
            :bClrHeader    := {|| { CLR_GREEN, 155 } }
         END
      NEXT

      // Search GETBAR
      oBrw[ 1 ]:lGetBar   := .T.

      FOR EACH cCol in { "
First", "Last", "Street", "City", "Zip" }

         WITH OBJECT oBrw[ 1 ]:oCol( cCol )

            :uBarGetVal    := uValBlank( :Value )
            :cBarGetPic    := :cEditPicture
            :bClrEdit      := {|| { CLR_BLACK, MY_LIGHTYELLOW } }

            :lBarGetOnKey := .T. // after having setfocus the oBrowse object, the end user can insert the characters directly into the get
            :cBarGetBmp := hBmp // this for show the Bitmap on the get
            :bBarGetAction := {|| ( oBrw[ 1 ]:cAlias )->( MARC_SETFILTER( oBrw[ 1 ] ) ) } // this for show the bitmap on the get and associated a action

         END

      NEXT

      WITH OBJECT oBrw[ 1 ]

         :lColChangeNotify := .T.
         :lFooter          := .T.
         :bRecSelHeader    := {|| "
Klant" }
         :bRecSelData      := {| o | o:KeyNo }
         :bRecSelFooter    := {| o | o:nLen }
         :oRecSelFont      := oFont3  // optional
         :nRecSelWidth     := "
99999" // required size
         :lHScroll      := .F.
         :lMultiSelect     := .T.

         :bLDClickDatas := {|| msginfo( "
Enter" )  }

         :nColDividerStyle := LINESTYLE_LIGHTGRAY
         :nRowDividerStyle := LINESTYLE_LIGHTGRAY
         :bClrRowFocus     := {|| { CLR_BLACK, RGB( 185, 220, 255 ) } }
         :nMarqueeStyle    := MARQSTYLE_HIGHLROWMS

         :bClrSelFocus = {|| { CLR_WHITE, RGB( 0, 128, 128 ) } } // CUANDO TIENE EL FOCUS

         :oHeaderFonts     := oBold

         :bKeyDown   := {| k | IF ( K == VK_DELETE, Del_row( oBrw[ 1 ] ), NIL ) }

      END

      oBrw[ 1 ]:CreateFromCode()
      oBrw[ 1 ]:setfocus()

      ACTIVATE DIALOG oDlgRB[ 1 ] NOWAIT ;
         ON INIT ( oDlgRB[ 1 ]:Move( aCoords[ 1 ] + 0, aCoords[ 2 ] + 0,,, .T. ) );
         VALID lEscapa

      oFont1:End()
      oBold:End()
      oFont:End()
      oFont3:End()
      oFontS:End()
      oFontXS:End()

   ELSE

      oDlgRB[ 1 ]:Show()

   ENDIF

RETURN NIL

FUNCTION Dialog02()

   LOCAL aCoords := GetCoors( oWnd:oWndClient ), oBrush, oGet, cTxtGet := "
Get in Dialog 02"
   LOCAL oFont1, oBmpAlpha
   LOCAL lEscapa := .F.

   HideDlg( 2 )

   IF ValType( oDlgRB[ 2 ] ) <> "
O"

      oBmpAlpha := TImage():Define(, "
..\Bitmaps\AlphaBmp\World.bmp" )

      DEFINE FONT oFont1 NAME "
Ms Sans Serif" SIZE 0, - 8 BOLD
      DEFINE BRUSH oBrush FILE "
..\Bitmaps\BackGrnd\Stone.bmp"

      DEFINE DIALOG oDlgRB[ 2 ] FROM 0, 0 TO 538, 782 OF oWnd:oWndClient PIXEL // COLORS RGB(0,0,0),RGB(255,255,255)

      oDlgRB[ 2 ]:nStyle := nOR( WS_CHILD )
      oDlgRB[ 2 ]:oBrush := oBrush
      oDlgRB[ 2 ]:lTransparent := .T.

      @ 30, 30 SAY "
Some text bla bla bla in DIALOG 02" OF oDlgRB[ 2 ] PIXEL ;
         COLOR nRGB( 0, 0, 125 ) FONT oFont1

      @ 45, 30 GET oGet VAR cTxtGet OF oDlgRB[ 2 ] PIXEL

      ACTIVATE DIALOG oDlgRB[ 2 ] NOWAIT ; // CENTERED
         ON INIT ( oDlgRB[ 2 ]:Move( aCoords[ 1 ] + 0, aCoords[ 2 ] + 0,,, .T. ) ) ;
         ON PAINT ( ABPaint( hDC, 365, 230, oBmpAlpha:hBitmap, 255 ) );
         VALID lEscapa
   ELSE

      oDlgRB[ 2 ]:Show()

   ENDIF

RETURN NIL

FUNCTION Dialog03()

   LOCAL aCoords := GetCoors( oWnd:oWndClient ), oBrush, oGet, cTxtGet := "
Get in Dialog 03"
   LOCAL oFont1, oBmpAlpha
   LOCAL lEscapa := .F.

   HideDlg( 3 )

   IF ValType( oDlgRB[ 3 ] ) <> "
O"

      oBmpAlpha := TImage():Define(, "
..\Bitmaps\AlphaBmp\World.bmp" )

      DEFINE BRUSH oBrush FILE "
..\Bitmaps\BackGrnd\Stone.bmp"

      DEFINE FONT oFont1 NAME "
Ms Sans Serif" SIZE 0, - 8 BOLD

      DEFINE DIALOG oDlgRB[ 3 ] FROM 0, 0 TO 538, 782 OF oWnd:oWndClient PIXEL

      oDlgRB[ 3 ]:nStyle := nOR( WS_CHILD ) // ,WS_THICKFRAME
      oDlgRB[ 3 ]:oBrush := oBrush
      oDlgRB[ 3 ]:lTransparent := .T.

      @ 40, 40 SAY "
Some text bla bla bla in DIALOG 03" OF oDlgRB[ 3 ] PIXEL COLOR nRGB( 0, 0, 125 ) FONT oFont1

      @ 45, 40 GET oGet VAR cTxtGet OF oDlgRB[ 3 ] PIXEL

      ACTIVATE DIALOG oDlgRB[ 3 ] NOWAIT ; // CENTERED
         ON INIT ( oDlgRB[ 3 ]:Move( aCoords[ 1 ] + 0, aCoords[ 2 ] + 0,,, .T. ) );
         ON PAINT ( ABPaint( hDC, 395, 260, oBmpAlpha:hBitmap, 255 ) );
         VALID lEscapa

   ELSE

      oDlgRB[ 3 ]:Show()

   ENDIF

   RETURN NIL

FUNCTION HideDlg( nDlg )

   LOCAL i := 1

   FOR i := 1 TO Len( oDlgRB )

      IF ValType( oDlgRB[ i ] ) == "
O"
         oDlgRB[ i ]:Hide()
      ENDIF

   NEXT

   RETURN NIL

FUNCTION MyErrorAction( cErrorLogFileName, oError )

   LOCAL cErrScreen := "
"

   MsgInfo( "
Er is een fout opgetreden in het programma.  Gelieve het programma opnieuw te starten" )

RETURN NIL

FUNCTION lookup_klant( cKlant )

   msginfo( cKlant )

RETURN NIL

FUNCTION dbftonen() // ??

   LOCAL n, j, nTarget
   LOCAL cErrorlog := "
"

   cErrorLog += CRLF + "
DataBases in use" + CRLF + "================" + CRLF

   FOR n = 1 TO 255

      IF ! Empty( Alias( n ) )

         cErrorLog += CRLF + Str( n, 3 ) + "
: " + If( Select() == n, "=> ", "   " ) + ;
            ( Alias( n ) )->( dbInfo( DBI_FULLPATH ) ) + Space( 2 ) + "
RddName: " + ;
            ( Alias( n ) )->( rddName() ) + CRLF
         cErrorLog += "
    =======================================================" + CRLF
         cErrorLog += "
    RecNo    RecCount    BOF   EOF" + CRLF
         cErrorLog += "
  " + Transform( ( Alias( n ) )->( RecNo() ), "9999999" ) + ;
            "
    " + Transform( ( Alias( n ) )->( RecCount() ), "9999999" ) + ;
            "
   " + cValToChar( ( Alias( n ) )->( Bof() ) ) + ;
            "
  " + cValToChar( ( Alias( n ) )->( Eof() ) ) + Transform( ( Alias( n ) )->( ordKeyCount() ), "9999999" )  + CRLF + CRLF

         IF ( Alias( n ) )->( rddName() ) != "
ARRAYRDD"
            cErrorLog += "
    Indexes in use " + Space( 23 ) + "TagName" + CRLF + CRLF
            FOR j = 1 TO 25
               IF ! Empty( ( Alias( n ) )->( IndexKey( j ) ) )
                  cErrorLog += Space( 8 ) + ;
                     If( ( Alias( n ) )->( IndexOrd() ) == j, "
=> ", "   " ) + ;
                     PadR( ( Alias( n ) )->( IndexKey( j ) ), 35 ) + ;
                     ( Alias( n ) )->( ordName( j ) ) + ;
                     CRLF
               ENDIF
            NEXT
            cErrorLog += CRLF + "
    Relations in use" + CRLF + CRLF
            FOR j = 1 TO 8
               IF ! Empty( ( nTarget := ( Alias( n ) )->( dbRSelect( j ) ) ) )
                  cErrorLog += Space( 3 ) + Str( j ) + "
: " + ;
                     "
TO " + ( Alias( n ) )->( dbRelation( j ) ) + ;
                     "
INTO " + Alias( nTarget ) + CRLF
                  // uValue = ( Alias( n ) )->( DbRelation( j ) )
                  // cErrorLog += cValToChar( ordsetfocus( uValue ) ) + CRLF
               ENDIF
            NEXT

         ENDIF
      ENDIF
   NEXT

   MemoEdit( @cErrorlog, "
Geopende Databases", 10, 60, 60, 150 )

RETURN NIL

FUNCTION Popfiles()

   LOCAL oDlgpop, oBar, oBtnSave, oBold, oFont, oFontBig, oBrush

   SET 3DLOOK ON

   DEFINE BRUSH oBrush STYLE TILED

   DEFINE FONT oBold    NAME 'CALIBRI' SIZE 0, -12 BOLD
   DEFINE FONT oFont    NAME "
CALIBRI" SIZE 0, -14
   DEFINE FONT oFontBig NAME "
CALIBRI" SIZE 0, -24

   DEFINE DIALOG oDlgpop SIZE 200, 100 PIXEL TRUEPIXEL ;
      TITLE "
Klantenbestand : "                        ;
      GRADIENT { { 1, nRGB( 125, 155, 175 ), nRGB( 125, 155, 175 ) } }

   DEFINE BUTTONBAR oBar OF oDlgpop SIZE 45, 45 2007

   DEFINE BUTTON oBtnSave OF oBar FILE "
bitmaps\save.bmp" PROMPT "Data"  ;
      GROUP TOOLTIP "
Gegevens" ;
      ACTION popopenfile()

   DEFINE BUTTON OF oBar FILE "
bitmaps\print.bmp" PROMPT "Struct" ;
      TOOLTIP "
Structure" ;
      ACTION popopenstruc()

   ACTIVATE DIALOG oDlgpop

   oBrush:End()
   oBold:End()
   oFont:End()
   oFontBig:End()

RETURN NIL

FUNCTION popopenfile()

   LOCAL oBrw, cFile, aStruc

   IF .NOT. Empty( cFile := cGetFile(   "
DataFile (*.DBF)|*.dbf|",          ;
         "
Select Data File to Browse", 1,     ;
         "
\programmas\fotoselect" ) )

      USE &cFile ALIAS datastruc NEW

      aStruc := dbStruct()

      xbrowser( "
datastruc" ) SHOW RECID FASTEDIT AUTOSORT ;
         SETUP ( oBrw:lIncrFilter := .T., oBrw:lSeekWild := .T. )

      CLOSE datastruc

   ENDIF

RETURN NIL

FUNCTION popopenstruc()

   LOCAL cFile
   LOCAL aStruc

   IF .NOT. Empty( cFile := cGetFile(   "
DataFile (*.DBF)|*.dbf|",          ;
         "
Select Data File to Browse", 1,     ;
         "
\programmas\fotoselect" ) )

      USE &cFile ALIAS DATASTRUC NEW SHARED

      aStruc := datastruc->( dbStruct() )

      xbrowser( aStruc )

      CLOSE datastruc

   ENDIF

RETURN NIL

FUNCTION NETOPEN( cFile, cIndex, lMode, cAlias, nSeconds, lNewArea, cDriver, ;
                  lReadOnly )

   LOCAL nWaitTime, lContinue := .T., lSuccess := .F., TSEL := 0

   DEFAULT lMode     :=  .T.                     // shared mode
   DEFAULT cIndex := "
"
   DEFAULT nSeconds  :=  3
   DEFAULT cAlias    := cFile
   DEFAULT lNewArea  :=  .T.
   DEFAULT cDriver   := "
DBFCDX"
   DEFAULT lReadOnly :=  .F.

   SET DEFAULT TO LOCAL_PATH

   nWaitTime := nSeconds

   cFile := AllTrim( cFile ) + "
.dbf"

   IF lServer

      cFile := server_path + cFile

      IF .NOT. FILE( cFile )

         MsgInfo( "
Database not created correctly.", "Attention" )

         RETURN( .F. )

      ENDIF

   ELSE

      cFile := local_path + cFile

      IF .NOT. FILE( cFile )

         MsgInfo( "
Database not created correctly.", "Attention" )

         RETURN( .F. )

      ENDIF

   ENDIF

   // bestand het bestand
   IF ! File( cFile )

      Exit( "
Bestand " + CFILE + ".DBF is afwezig" )

   ENDIF

   // verify driver is valid
   IF AScan( rddList(), cDriver ) == 0

      MSGSTOP( "
Driver " + Cdriver + "  afwezig" )

      Exit()

   ENDIF

   // Indien reeds geopend, alles ok, select waar
   IF Select( cAlias ) # 0

      MsgInfo( "
File : " + cAlias + " is reeds geopend" )

      TSEL := Select( cAlias )

      Select( TSEL )

      lContinue := .T.
      lNewArea  := .F.

   ENDIF

   // while continuing to attempt open
   WHILE lContinue // while .not. timed-out

      SYSREFRESH()

      WHILE nSeconds > 0 .AND. lContinue

         SYSREFRESH()

         // dbUseArea( lNewArea, cDriver, cFile, cAlias, ( .not. lMode ), lReadOnly )
         dbUseArea( lNewArea, cDriver, cFile, cAlias, lMode, lReadOnly )

         // check for success/failure
         IF NetErr()
            nSeconds--
            lSuccess  := .F.
         ELSE
            // open successful
            nSeconds  := 0
            lSuccess  := .T.
            lContinue := .F.
         ENDIF

      ENDDO

      IF .NOT. lSuccess

         nSeconds  := nWaitTime

         MSGSTOP( "
Bestand " + CFILE + " Alias : " + cAlias + " is geopend door een andere gebruiker" + CRLF + CRLF + "Gelieve even te wachten" )

         lSuccess  := .F.
         lContinue := .T.
         lNewArea  := .T.

      ENDIF

      IF !Empty( cIndex )

         &cAlias->( dbSetOrder( cIndex ) )

      ENDIF

   ENDDO

RETURN lSuccess

CLASS TSeek STATIC

   DATA oBrw

   METHOD New( oBrw ) CONSTRUCTOR
   METHOD SetText( c ) INLINE ::oBrw:RefreshFooters()

ENDCLASS

METHOD New( oBrw ) CLASS TSeek

   ::oBrw   := oBrw

RETURN Self

FUNCTION del_row( oBrw )

   IF MsgYesNo( "
Deze regel wissen" )

      oBrw:delete()

   ENDIF

RETURN NIL

FUNCTION Exit( cErrInfo )

   cErrInfo += CRLF + "
Gelieve deze fout te melden" + CRLF + CRLF + ;
                      "
Het Programma zal nu eindigen"

   CLOSE ALL

   MSGSTOP( cErrInfo )

   SET RESOURCES TO

   ErrorLevel( 1 )

   DbCommitAll()
   DbUnLockAll()
   DbCloseAll()
   FreeResources()
   Release All
   SysRefresh()
   HB_GCALL( .T. )

   CLEAR MEMORY

   PostQuitMessage( 0 )

   QUIT

RETURN NIL

FUNCTION MARC_SETFILTER( oBrw ) // SETFILTER()?? INTERN COMMAND.

   LOCAL cFilter := "
"
   LOCAL n, oCol, uVal, cType

   FOR n := 1 TO Len( oBrw:aCols )

      oCol  := oBrw:aCols[ n ]

      IF ! Empty( uVal := oCol:uBarGetVal )

         IF !Empty( cFilter )
            cFilter  += "
.AND. "
         ENDIF

         cType    := ValType( uVal )

         DO CASE
         CASE cType == 'C'
            uVal     := Upper( AllTrim( uVal ) )
   // cFilter += '"
' + uVal + '" $ UPPER( ' + FieldName( n ) + " )"
            cFilter += '"
' + uVal + '" $ UPPER( ' + oCol:CExpr + " )"
         OTHERWISE
   // cFilter  += FieldName( n ) + "
== " + cValToChar( uVal )
            cFilter  += oCol:cExpr + "
== " + cValToChar( uVal )
         ENDCASE
      ENDIF

   NEXT
   // ******************************
   // /
   // msginfo(cFilter)
   // msgGet( "
title", "message", @cFilter )

   IF Empty( cFilter )

      IF ! Empty( dbFilter() )
         dbClearFilter()
         oBrw:Refresh()
      ENDIF

   ELSE

      IF !( dbFilter() == cFilter )
         SET FILTER TO &cFilter
         GO TOP
         oBrw:Refresh()
      ENDIF

   ENDIF

   oBrw:SetFocus()

RETURN NIL

//
//   SETKEY( VK_F10, { | nKey | PROFILES() } )

FUNCTION PROFILES()

   ? [????????]

RETURN NIL

//   SETKEY( VK_F12, { | nKey | DBFTONEM() } )
FUNCTION DBFTONEM()

   ? [????????]

RETURN NIL

// FIN / END


Regards, saludos.
João Santos - São Paulo - Brasil - Phone: +55(11)95150-7341
User avatar
karinha
 
Posts: 7872
Joined: Tue Dec 20, 2005 7:36 pm
Location: São Paulo - Brasil

Re: Focus error on this new project

Postby Marc Venken » Thu Dec 09, 2021 1:44 pm

Can you use the mouse in the browse ?

I can't... It does nothing.

Also clicking on the folderextab, nothing happens.

I can click on the 1,2 and 3 button from the ribbonbar
Marc Venken
Using: FWH 23.04 with Harbour
User avatar
Marc Venken
 
Posts: 1456
Joined: Tue Jun 14, 2016 7:51 am
Location: Belgium

Re: Focus error on this new project

Postby Marc Venken » Thu Dec 09, 2021 2:08 pm

setkey( VK_F12,{|| Dbftonen() } )

setkey( VK_F10,{|| popfiles() })

F12 = Function that will show aal the open databases and indexes and some info for looking what is going on (debug mode)
F10 = Function to open a selected dbf in order to see that the field content is, so that I can easily add a field to a xbrowse (debug mode)

//--------------------------------------------------------------
MENU oMenu 2007
// ??
ENDMENU

No idea, it was inside the sample program : Ribbon2 that I used as start sample
Maybe not needed ))

//--------------------------------------------------------------
// oFld:aDialogs[ 1 ]:bGotfocus := {|| msginfo( "Hier Folder" ) }

Testing rule to see if anything would happen when I click on folder1 (but is didn't)

//--------------------------------------------------------------

I also see that you take time to set the locals, public variables and also the xxx:end() with fonts etc...

Because it belongs to good programming?
I think I should also start doing this right ?

//--------------------------------------------------------------

FUNCTION MARC_SETFILTER( oBrw ) // SETFILTER()?? INTERN COMMAND.

So, the setfilter I used is standard inside FW... Than I will try that one. I believe I once got it from a post of mr Rao, but it can be better in the FW version than
Will surely try it.
Marc Venken
Using: FWH 23.04 with Harbour
User avatar
Marc Venken
 
Posts: 1456
Joined: Tue Jun 14, 2016 7:51 am
Location: Belgium

Re: Focus error on this new project

Postby Marc Venken » Thu Dec 09, 2021 2:16 pm

This is also in the code because of the sample. Maybe not needed also.

I don't open dialogs when other are already open. In best way, I just open a extra Xbrowse for looking up (customers, products,...)

// from the sample, but not mine

HideDlg( 1 )

IF ValType( oDlgRB[ 1 ] ) <> "O"
....
endif

oDlgRB[ 1 ]:nStyle := nOR( WS_CHILD ) // ,WS_THICKFRAME
Marc Venken
Using: FWH 23.04 with Harbour
User avatar
Marc Venken
 
Posts: 1456
Joined: Tue Jun 14, 2016 7:51 am
Location: Belgium

Re: Focus error on this new project

Postby karinha » Thu Dec 09, 2021 3:21 pm

YES!! More or less. hahahahahahaha.

https://imgur.com/SuuZvEX

[url]Image[/url]

Regards.
João Santos - São Paulo - Brasil - Phone: +55(11)95150-7341
User avatar
karinha
 
Posts: 7872
Joined: Tue Dec 20, 2005 7:36 pm
Location: São Paulo - Brasil

Re: Focus error on this new project

Postby karinha » Thu Dec 09, 2021 3:27 pm

Marc, continue...

Code: Select all  Expand view  RUN

// \SAMPLES\MARC2.PRG  - 09/12/2021 - Modified by: Joao - Version 1.2

#include "fivewin.ch"
#include "Directry.ch"
#include "inkey.ch"
#include 'ord.ch'
#include "ribbon.ch"
#include 'xbrowse.ch'

#define MY_GREEN   nRGB( 145, 214, 124)
#define MY_LIGHTGREEN nRGB( 236, 255, 224)
#define MY_LIGHTYELLOW nRGB( 255, 251, 142)
#define MY_LIGHTBLUE nRGB( 214, 229, 255)
#define MY_PAARS nRGB( 232, 201, 255)
#define MY_YELLOW nRGB( 255, 220, 96)

ANNOUNCE RDDSYS
REQUEST OrdKeyNo, OrdKeyCount, OrdCreate, OrdKeyGoto
REQUEST DBFCDX, DBFFPT

STATIC oWnd, oDlg
STATIC oDlgRB[ 3 ]
STATIC SERVER_PATH, LOCAL_PATH, oFld, CDRIVE, cLocal
STATIC lServer := .F.

FUNCTION Main()

   LOCAL sys_versie := "Dec 2021 - 02/12"
   LOCAL cErrorLogFileName := "MyLog.log"
   LOCAL oFol, oDlg, oRBar, oMenu, oMenuWnd, oBrush1, oGr, oGr1, oGr2, oGr3, ;
         oGr4, oSay1, oBmp, oFont1, oCursor, oBtn2, oBtn3, oBtn4
   LOCAL aBitmaps := { "..\bitmaps\alphabmp\facebook.bmp",;
                       "..\bitmaps\alphabmp\windows.bmp",;
                       "..\bitmaps\alphabmp\game.bmp",;
                       "..\bitmaps\alphabmp\viddler.bmp",;
                       "..\bitmaps\alphabmp\mail.bmp",;
                       "..\bitmaps\alphabmp\call.bmp",;
                       "..\bitmaps\alphabmp\settings2.bmp",;
                       "..\bitmaps\alphabmp\exit.bmp" }

   RDDSETDEFAULT("DBFCDX")

   SET CENTURY ON
   SET DATE BRITISH
   SET TIME FORMAT TO "HH:MM:SS"
   SET EPOCH TO YEAR( DATE() ) - 30
   SET SOFTSEEK OFF
   SET WRAP ON
   SETCANCEL( .F. )
   SET CONFIRM OFF
   SET DELETED ON
   SET _3DLOOK ON
   SET UNIQUE OFF
   SET ESCAPE OFF
   SET EXACT ON
   SET EXCLUSIVE OFF
   SET MULTIPLE OFF

   SERVER_PATH := "\\CAROLIEN-PC\MARC\"
   LOCAL_PATH  := CURDRIVE()+"
:\MARC\"
   cDrive      := "
C:\MARC\"                     // DEZE MOET
   cLocal      := "
C:\MARC\"                     // DEZE MOET

   If .NOT. lIsDir( LOCAL_PATH )

      LMkdir( LOCAL_PATH )

   Endif

   FW_SetUnicode( .T. )

   SetBalloon( .T. ) // Balloon shape required for tooltips

   SkinButtons()

   SetGetColorFocus( CLR_GREEN )

   SETKEY( VK_F10, { | nKey | PROFILES() } )
   SETKEY( VK_F12, { | nKey | DBFTONEN() } ) //??

   xbrNumFormat( "
E", .T. )  // "E" for European, "A" for American and others // .t. for showing thousand separators

   MENU oMenu 2007
      // ??
   ENDMENU

   DEFINE FONT oFont1 NAME "
Arial" SIZE 0, - 30 // BOLD

   DEFINE CURSOR oCursor HAND
   DEFINE BRUSH oBrush1 COLOR nRGB( 223, 233, 244 )

   DEFINE WINDOW oWnd TITLE "
Maveco Bedrijfskleding " + FWVERSION ;
      FROM 0, 0 TO 1030, 1920 pixel MDI MENU oMenu BRUSH oBrush1

   DEFINE RIBBONBAR oRBar WINDOW oWnd PROMPT "
Klanten", "Leveranciers", "Ingeven Documenten";
      HEIGHT 130 TOPMARGIN 25

   // "
Marc, enter the data from folders. oFld:aDialogs[ 2, 3, 4, ETC. ]"
   Marc_FolderEx( oWnd ) // new:

   ADD GROUP oGr  RIBBON oRBar TO OPTION 1 PROMPT "
Clipboard" width 130 ;
      BITMAP "
..\bitmap\fivetech.BMP"

   @ 02, 05 ADD BUTTON oBtn2 GROUP oGr BITMAP "
bitmaps\cut16.BMP" ;
      SIZE 75, 20 PROMPT "
Dialog 01"  MOSTLEFT round ;
      action ( Dialog01() )

   @ 24, 05 ADD BUTTON oBtn3 GROUP oGr BITMAP "
bitmaps\copy16.BMP" ;
      SIZE 75, 20 PROMPT "
Dialog 02"  MOSTLEFT round ;
      action( Dialog02() )

   @ 46, 05 ADD BUTTON oBtn4 GROUP oGr BITMAP "
bitmaps\paste16.BMP" ;
      SIZE 75, 20 PROMPT "
Dialog 03"  MOSTLEFT round ;
      action( Dialog03() )

   ADD GROUP oGr2 RIBBON oRBar TO OPTION 1 PROMPT "
Exit" width 70 ;
      BITMAP "
bitmap\fivetech.bmp"

   @ 15, 20 ADD BUTTON oBtn4 GROUP oGr2 BITMAP "
bitmaps\32x32\quit.BMP" ;
      SIZE 34, 52 PROMPT "
Exit" action( oWnd:End() )

   SET MESSAGE OF oWnd TO "
Version : " + sys_versie ;
      CENTERED CLOCK KEYBOARD 2007

   WndCenter( oWnd:hWnd )

   ACTIVATE WINDOW oWnd MAXIMIZED

   oBrush1:End()
   oRBar:End()

RETURN NIL

FUNCTION Marc_FolderEx( oWnd )

   LOCAL oWndChild, i, oFont1
   LOCAL aBitmaps := { "
..\bitmaps\alphabmp\facebook.bmp",;
                       "
..\bitmaps\alphabmp\windows.bmp",;
                       "
..\bitmaps\alphabmp\game.bmp",;
                       "
..\bitmaps\alphabmp\viddler.bmp",;
                       "
..\bitmaps\alphabmp\mail.bmp",;
                       "
..\bitmaps\alphabmp\call.bmp",;
                       "
..\bitmaps\alphabmp\settings2.bmp",;
                       "
..\bitmaps\alphabmp\exit.bmp" }

   DEFINE FONT oFont1 NAME "
Arial" SIZE 0, - 26 // BOLD

   DEFINE WINDOW oWndChild MDICHILD TITLE "
TFolderex - Testing -"

    @ 3, 3 FOLDEREX oFld PIXEL ADJUST ROUND 5                                 ;
       PROMPT "
Basis", "Documenten", "Personen", "Facturen"                   ;
       BITMAPS "
..\bitmaps\alphabmp\Facebook.bmp",                            ;
               "
..\bitmaps\alphabmp\myspace.bmp",                             ;
               "
..\bitmaps\alphabmp\Twitter.bmp",                             ;
               "
..\bitmaps\alphabmp\mail.bmp",;

   oFld:aEnable = { .T., .T., .T., .T., .F. }
   oFld:SetOption( 1 )
   oFld:Show()

   Dialog01( oFld )      // ACTION IN DIALOG OF FOLDER 01

   Dialog_Marc02( oFld ) // ACTION IN DIALOG OF FOLEDR 02

   Dialog_Marc03( oFld ) // ACTION IN DIALOG OF FOLEDR 03

   Dialog_Marc04( oFld ) // ACTION IN DIALOG OF FOLEDR 04

   SET FONT OF oFld  TO oFont1
   
   ACTIVATE WINDOW oWndChild MAXIMIZED CENTERED

RETURN NIL

FUNCTION Dialog_Marc02( oFld )

   ? "
Marc, enter the data from folder 2 here. oFld:aDialogs[ 2 ]"

   @ 3,10 FOLDEREX OF oFld:aDialogs[ 2 ] PIXEL SIZE 450, 190 ;

RETURN NIL

FUNCTION Dialog_Marc03( oFld )

   ? "
Marc, enter the data from folder 3 here. oFld:aDialogs[ 3 ]"

   @ 3,10 FOLDEREX OF oFld:aDialogs[ 3 ] PIXEL SIZE 450, 190 ;

RETURN NIL

FUNCTION Dialog_Marc04( oFld )

   ? "
Marc, enter the data from folder 4 here. oFld:aDialogs[ 4 ]"

   @ 3,10 FOLDEREX OF oFld:aDialogs[ 4 ] PIXEL SIZE 450, 190 ;

RETURN NIL

FUNCTION Dialog01( oFld )

   LOCAL oFont1, oBold, oFont, oFont3, oFontS, oFontXS
   LOCAL aCoords := GetCoors( oWnd:oWndClient ), oBrush, oGet
   LOCAL sys_klant := Space( 10 ), nWild := 1
   LOCAL oBmpAlpha
   LOCAL lEscapa := .F.
   LOCAL oBrw[ 1 ], aVelden := {}, cCol
   LOCAL hBmp := ReadBitmap( 0, "
bitmaps\search.bmp" )

   netopen( "
customer", "last" )

   HideDlg( 1 )

   IF ValType( oDlgRB[ 1 ] ) <> "
O"

      DEFINE FONT oFont1 NAME "
Ms Sans Serif" SIZE 0, - 8 BOLD
      DEFINE FONT oBold NAME 'CALIBRI' SIZE 0, - 12 BOLD
      DEFINE FONT oFont NAME "
CALIBRI" SIZE 0, - 14
      DEFINE FONT oFont3 NAME "
Segoe UI" SIZE 0, - 12
      DEFINE FONT oFontS NAME "
Segoe UI" SIZE 0, - 09
      DEFINE FONT oFontXS NAME "
Segoe UI" SIZE 0, - 08

      DEFINE BRUSH oBrush FILE "
Bitmaps\BackGrnd\Stone.bmp"

      DEFINE DIALOG oDlgRB[ 1 ] FROM 0, 0 TO 700, 1900 OF oFld:aDialogs[ 1 ] PIXEL COLORS RGB( 0, 0, 0 ), RGB( 255, 255, 255 )

      oDlgRB[ 1 ]:nStyle := nOR( WS_CHILD ) // ,WS_THICKFRAME

      aVelden :=  { ;
         { "
ID", "ID", NIL,  90 }, ;
         { "
First", "First", NIL,  350 }, ;
         { "
Last", "Last", NIL, 300 }, ;
         { "
Street", "Street", NIL, 300 }, ;
         { "
City", "City", NIL, 200 }, ;
         { "
Zip", "Zip", NIL, 150 } }

      @ 0, 0 XBROWSE oBrw[ 1 ] size - 05, - 20 PIXEL OF oDlgRB[ 1 ] font oFont ;
         DATASOURCE "
customer" ;
         COLUMNS aVelden ;
         AUTOSORT CELL LINES NOBORDER FOOTERS

      oBrw[ 1 ]:SetChecks()
      oBrw[ 1 ]:nStretchCol         := STRETCHCOL_WIDEST

      oBrw[ 1 ]:lHScroll := .F.
      oBrw[ 1 ]:nHeadStrAligns  := AL_CENTER

      FOR EACH cCol in { "
First", "Last", "Street" }
         WITH OBJECT oBrw[ 1 ]:oCol( cCol )
            :nEditType     := EDIT_GET
            :bClrHeader    := {|| { CLR_GREEN, 155 } }
         END
      NEXT

      // Search GETBAR
      oBrw[ 1 ]:lGetBar   := .T.

      FOR EACH cCol in { "
First", "Last", "Street", "City", "Zip" }

         WITH OBJECT oBrw[ 1 ]:oCol( cCol )

            :uBarGetVal    := uValBlank( :Value )
            :cBarGetPic    := :cEditPicture
            :bClrEdit      := {|| { CLR_BLACK, MY_LIGHTYELLOW } }

            :lBarGetOnKey := .T. // after having setfocus the oBrowse object, the end user can insert the characters directly into the get
            :cBarGetBmp := hBmp // this for show the Bitmap on the get
            :bBarGetAction := {|| ( oBrw[ 1 ]:cAlias )->( MARC_SETFILTER( oBrw[ 1 ] ) ) } // this for show the bitmap on the get and associated a action

         END

      NEXT

      WITH OBJECT oBrw[ 1 ]

         :lColChangeNotify := .T.
         :lFooter          := .T.
         :bRecSelHeader    := {|| "
Klant" }
         :bRecSelData      := {| o | o:KeyNo }
         :bRecSelFooter    := {| o | o:nLen }
         :oRecSelFont      := oFont3  // optional
         :nRecSelWidth     := "
99999" // required size
         :lHScroll      := .F.
         :lMultiSelect     := .T.

         :bLDClickDatas := {|| msginfo( "
Enter" )  }

         :nColDividerStyle := LINESTYLE_LIGHTGRAY
         :nRowDividerStyle := LINESTYLE_LIGHTGRAY
         :bClrRowFocus     := {|| { CLR_BLACK, RGB( 185, 220, 255 ) } }
         :nMarqueeStyle    := MARQSTYLE_HIGHLROWMS

         :bClrSelFocus = {|| { CLR_WHITE, RGB( 0, 128, 128 ) } } // CUANDO TIENE EL FOCUS

         :oHeaderFonts     := oBold

         :bKeyDown   := {| k | IF ( K == VK_DELETE, Del_row( oBrw[ 1 ] ), NIL ) }

      END

      oBrw[ 1 ]:CreateFromCode()
      oBrw[ 1 ]:setfocus()

      ACTIVATE DIALOG oDlgRB[ 1 ] NOWAIT ;
         ON INIT ( oDlgRB[ 1 ]:Move( aCoords[ 1 ] + 0, aCoords[ 2 ] + 0,,, .T. ) );
         VALID lEscapa

      oFont1:End()
      oBold:End()
      oFont:End()
      oFont3:End()
      oFontS:End()
      oFontXS:End()

   ELSE

      oDlgRB[ 1 ]:Show()

   ENDIF

RETURN NIL

FUNCTION Dialog02( oFld )

   LOCAL aCoords := GetCoors( oWnd:oWndClient ), oBrush, oGet, cTxtGet := "
Get in Dialog 02"
   LOCAL oFont1, oBmpAlpha
   LOCAL lEscapa := .F.

   HideDlg( 2 )

   IF ValType( oDlgRB[ 2 ] ) <> "
O"

      oBmpAlpha := TImage():Define(, "
..\Bitmaps\AlphaBmp\World.bmp" )

      DEFINE FONT oFont1 NAME "
Ms Sans Serif" SIZE 0, - 8 BOLD
      DEFINE BRUSH oBrush FILE "
..\Bitmaps\BackGrnd\Stone.bmp"

      DEFINE DIALOG oDlgRB[ 2 ] FROM 0, 0 TO 538, 782 OF oWnd:oWndClient PIXEL // COLORS RGB(0,0,0),RGB(255,255,255)

      oDlgRB[ 2 ]:nStyle := nOR( WS_CHILD )
      oDlgRB[ 2 ]:oBrush := oBrush
      oDlgRB[ 2 ]:lTransparent := .T.

      @ 30, 30 SAY "
Some text bla bla bla in DIALOG 02" OF oDlgRB[ 2 ] PIXEL ;
         COLOR nRGB( 0, 0, 125 ) FONT oFont1

      @ 45, 30 GET oGet VAR cTxtGet OF oDlgRB[ 2 ] PIXEL

      ACTIVATE DIALOG oDlgRB[ 2 ] NOWAIT ; // CENTERED
         ON INIT ( oDlgRB[ 2 ]:Move( aCoords[ 1 ] + 0, aCoords[ 2 ] + 0,,, .T. ) ) ;
         ON PAINT ( ABPaint( hDC, 365, 230, oBmpAlpha:hBitmap, 255 ) );
         VALID lEscapa
   ELSE

      oDlgRB[ 2 ]:Show()

   ENDIF

RETURN NIL

FUNCTION Dialog03()

   LOCAL aCoords := GetCoors( oWnd:oWndClient ), oBrush, oGet, cTxtGet := "
Get in Dialog 03"
   LOCAL oFont1, oBmpAlpha
   LOCAL lEscapa := .F.

   HideDlg( 3 )

   IF ValType( oDlgRB[ 3 ] ) <> "
O"

      oBmpAlpha := TImage():Define(, "
..\Bitmaps\AlphaBmp\World.bmp" )

      DEFINE BRUSH oBrush FILE "
..\Bitmaps\BackGrnd\Stone.bmp"

      DEFINE FONT oFont1 NAME "
Ms Sans Serif" SIZE 0, - 8 BOLD

      DEFINE DIALOG oDlgRB[ 3 ] FROM 0, 0 TO 538, 782 OF oWnd:oWndClient PIXEL

      oDlgRB[ 3 ]:nStyle := nOR( WS_CHILD ) // ,WS_THICKFRAME
      oDlgRB[ 3 ]:oBrush := oBrush
      oDlgRB[ 3 ]:lTransparent := .T.

      @ 40, 40 SAY "
Some text bla bla bla in DIALOG 03" OF oDlgRB[ 3 ] PIXEL COLOR nRGB( 0, 0, 125 ) FONT oFont1

      @ 45, 40 GET oGet VAR cTxtGet OF oDlgRB[ 3 ] PIXEL

      ACTIVATE DIALOG oDlgRB[ 3 ] NOWAIT ; // CENTERED
         ON INIT ( oDlgRB[ 3 ]:Move( aCoords[ 1 ] + 0, aCoords[ 2 ] + 0,,, .T. ) );
         ON PAINT ( ABPaint( hDC, 395, 260, oBmpAlpha:hBitmap, 255 ) );
         VALID lEscapa

   ELSE

      oDlgRB[ 3 ]:Show()

   ENDIF

   RETURN NIL

FUNCTION HideDlg( nDlg )

   LOCAL i := 1

   FOR i := 1 TO Len( oDlgRB )

      IF ValType( oDlgRB[ i ] ) == "
O"
         oDlgRB[ i ]:Hide()
      ENDIF

   NEXT

   RETURN NIL

FUNCTION MyErrorAction( cErrorLogFileName, oError )

   LOCAL cErrScreen := "
"

   MsgInfo( "
Er is een fout opgetreden in het programma.  Gelieve het programma opnieuw te starten" )

RETURN NIL

FUNCTION lookup_klant( cKlant )

   msginfo( cKlant )

RETURN NIL

FUNCTION dbftonen() // ??

   LOCAL n, j, nTarget
   LOCAL cErrorlog := "
"

   cErrorLog += CRLF + "
DataBases in use" + CRLF + "================" + CRLF

   FOR n = 1 TO 255

      IF ! Empty( Alias( n ) )

         cErrorLog += CRLF + Str( n, 3 ) + "
: " + If( Select() == n, "=> ", "   " ) + ;
            ( Alias( n ) )->( dbInfo( DBI_FULLPATH ) ) + Space( 2 ) + "
RddName: " + ;
            ( Alias( n ) )->( rddName() ) + CRLF
         cErrorLog += "
    =======================================================" + CRLF
         cErrorLog += "
    RecNo    RecCount    BOF   EOF" + CRLF
         cErrorLog += "
  " + Transform( ( Alias( n ) )->( RecNo() ), "9999999" ) + ;
            "
    " + Transform( ( Alias( n ) )->( RecCount() ), "9999999" ) + ;
            "
   " + cValToChar( ( Alias( n ) )->( Bof() ) ) + ;
            "
  " + cValToChar( ( Alias( n ) )->( Eof() ) ) + Transform( ( Alias( n ) )->( ordKeyCount() ), "9999999" )  + CRLF + CRLF

         IF ( Alias( n ) )->( rddName() ) != "
ARRAYRDD"
            cErrorLog += "
    Indexes in use " + Space( 23 ) + "TagName" + CRLF + CRLF
            FOR j = 1 TO 25
               IF ! Empty( ( Alias( n ) )->( IndexKey( j ) ) )
                  cErrorLog += Space( 8 ) + ;
                     If( ( Alias( n ) )->( IndexOrd() ) == j, "
=> ", "   " ) + ;
                     PadR( ( Alias( n ) )->( IndexKey( j ) ), 35 ) + ;
                     ( Alias( n ) )->( ordName( j ) ) + ;
                     CRLF
               ENDIF
            NEXT
            cErrorLog += CRLF + "
    Relations in use" + CRLF + CRLF
            FOR j = 1 TO 8
               IF ! Empty( ( nTarget := ( Alias( n ) )->( dbRSelect( j ) ) ) )
                  cErrorLog += Space( 3 ) + Str( j ) + "
: " + ;
                     "
TO " + ( Alias( n ) )->( dbRelation( j ) ) + ;
                     "
INTO " + Alias( nTarget ) + CRLF
                  // uValue = ( Alias( n ) )->( DbRelation( j ) )
                  // cErrorLog += cValToChar( ordsetfocus( uValue ) ) + CRLF
               ENDIF
            NEXT

         ENDIF
      ENDIF
   NEXT

   MemoEdit( @cErrorlog, "
Geopende Databases", 10, 60, 60, 150 )

RETURN NIL

FUNCTION Popfiles()

   LOCAL oDlgpop, oBar, oBtnSave, oBold, oFont, oFontBig, oBrush

   SET 3DLOOK ON

   DEFINE BRUSH oBrush STYLE TILED

   DEFINE FONT oBold    NAME 'CALIBRI' SIZE 0, -12 BOLD
   DEFINE FONT oFont    NAME "
CALIBRI" SIZE 0, -14
   DEFINE FONT oFontBig NAME "
CALIBRI" SIZE 0, -24

   DEFINE DIALOG oDlgpop SIZE 200, 100 PIXEL TRUEPIXEL ;
      TITLE "
Klantenbestand : "                        ;
      GRADIENT { { 1, nRGB( 125, 155, 175 ), nRGB( 125, 155, 175 ) } }

   DEFINE BUTTONBAR oBar OF oDlgpop SIZE 45, 45 2007

   DEFINE BUTTON oBtnSave OF oBar FILE "
bitmaps\save.bmp" PROMPT "Data"  ;
      GROUP TOOLTIP "
Gegevens" ;
      ACTION popopenfile()

   DEFINE BUTTON OF oBar FILE "
bitmaps\print.bmp" PROMPT "Struct" ;
      TOOLTIP "
Structure" ;
      ACTION popopenstruc()

   ACTIVATE DIALOG oDlgpop

   oBrush:End()
   oBold:End()
   oFont:End()
   oFontBig:End()

RETURN NIL

FUNCTION popopenfile()

   LOCAL oBrw, cFile, aStruc

   IF .NOT. Empty( cFile := cGetFile(   "
DataFile (*.DBF)|*.dbf|",          ;
         "
Select Data File to Browse", 1,     ;
         "
\programmas\fotoselect" ) )

      USE &cFile ALIAS datastruc NEW

      aStruc := dbStruct()

      xbrowser( "
datastruc" ) SHOW RECID FASTEDIT AUTOSORT ;
         SETUP ( oBrw:lIncrFilter := .T., oBrw:lSeekWild := .T. )

      CLOSE datastruc

   ENDIF

RETURN NIL

FUNCTION popopenstruc()

   LOCAL cFile
   LOCAL aStruc

   IF .NOT. Empty( cFile := cGetFile(   "
DataFile (*.DBF)|*.dbf|",          ;
         "
Select Data File to Browse", 1,     ;
         "
\programmas\fotoselect" ) )

      USE &cFile ALIAS DATASTRUC NEW SHARED

      aStruc := datastruc->( dbStruct() )

      xbrowser( aStruc )

      CLOSE datastruc

   ENDIF

RETURN NIL

FUNCTION NETOPEN( cFile, cIndex, lMode, cAlias, nSeconds, lNewArea, cDriver, ;
                  lReadOnly )

   LOCAL nWaitTime, lContinue := .T., lSuccess := .F., TSEL := 0

   DEFAULT lMode     :=  .T.                     // shared mode
   DEFAULT cIndex := "
"
   DEFAULT nSeconds  :=  3
   DEFAULT cAlias    := cFile
   DEFAULT lNewArea  :=  .T.
   DEFAULT cDriver   := "
DBFCDX"
   DEFAULT lReadOnly :=  .F.

   SET DEFAULT TO LOCAL_PATH

   nWaitTime := nSeconds

   cFile := AllTrim( cFile ) + "
.dbf"

   IF lServer

      cFile := server_path + cFile

      IF .NOT. FILE( cFile )

         MsgInfo( "
Database not created correctly.", "Attention" )

         RETURN( .F. )

      ENDIF

   ELSE

      cFile := local_path + cFile

      IF .NOT. FILE( cFile )

         MsgInfo( "
Database not created correctly.", "Attention" )

         RETURN( .F. )

      ENDIF

   ENDIF

   // bestand het bestand
   IF ! File( cFile )

      Exit( "
Bestand " + CFILE + ".DBF is afwezig" )

   ENDIF

   // verify driver is valid
   IF AScan( rddList(), cDriver ) == 0

      MSGSTOP( "
Driver " + Cdriver + "  afwezig" )

      Exit()

   ENDIF

   // Indien reeds geopend, alles ok, select waar
   IF Select( cAlias ) # 0

      MsgInfo( "
File : " + cAlias + " is reeds geopend" )

      TSEL := Select( cAlias )

      Select( TSEL )

      lContinue := .T.
      lNewArea  := .F.

   ENDIF

   // while continuing to attempt open
   WHILE lContinue // while .not. timed-out

      SYSREFRESH()

      WHILE nSeconds > 0 .AND. lContinue

         SYSREFRESH()

         // dbUseArea( lNewArea, cDriver, cFile, cAlias, ( .not. lMode ), lReadOnly )
         dbUseArea( lNewArea, cDriver, cFile, cAlias, lMode, lReadOnly )

         // check for success/failure
         IF NetErr()
            nSeconds--
            lSuccess  := .F.
         ELSE
            // open successful
            nSeconds  := 0
            lSuccess  := .T.
            lContinue := .F.
         ENDIF

      ENDDO

      IF .NOT. lSuccess

         nSeconds  := nWaitTime

         MSGSTOP( "
Bestand " + CFILE + " Alias : " + cAlias + " is geopend door een andere gebruiker" + CRLF + CRLF + "Gelieve even te wachten" )

         lSuccess  := .F.
         lContinue := .T.
         lNewArea  := .T.

      ENDIF

      IF !Empty( cIndex )

         &cAlias->( dbSetOrder( cIndex ) )

      ENDIF

   ENDDO

RETURN lSuccess

CLASS TSeek STATIC

   DATA oBrw

   METHOD New( oBrw ) CONSTRUCTOR
   METHOD SetText( c ) INLINE ::oBrw:RefreshFooters()

ENDCLASS

METHOD New( oBrw ) CLASS TSeek

   ::oBrw   := oBrw

RETURN Self

FUNCTION del_row( oBrw )

   IF MsgYesNo( "
Deze regel wissen" )

      oBrw:delete()

   ENDIF

RETURN NIL

FUNCTION Exit( cErrInfo )

   cErrInfo += CRLF + "
Gelieve deze fout te melden" + CRLF + CRLF + ;
                      "
Het Programma zal nu eindigen"

   CLOSE ALL

   MSGSTOP( cErrInfo )

   SET RESOURCES TO

   ErrorLevel( 1 )

   DbCommitAll()
   DbUnLockAll()
   DbCloseAll()
   FreeResources()
   Release All
   SysRefresh()
   HB_GCALL( .T. )

   CLEAR MEMORY

   PostQuitMessage( 0 )

   QUIT

RETURN NIL

FUNCTION MARC_SETFILTER( oBrw ) // SETFILTER()?? INTERN COMMAND.

   LOCAL cFilter := "
"
   LOCAL n, oCol, uVal, cType

   FOR n := 1 TO Len( oBrw:aCols )

      oCol  := oBrw:aCols[ n ]

      IF ! Empty( uVal := oCol:uBarGetVal )

         IF !Empty( cFilter )
            cFilter  += "
.AND. "
         ENDIF

         cType    := ValType( uVal )

         DO CASE
         CASE cType == 'C'
            uVal     := Upper( AllTrim( uVal ) )
   // cFilter += '"
' + uVal + '" $ UPPER( ' + FieldName( n ) + " )"
            cFilter += '"
' + uVal + '" $ UPPER( ' + oCol:CExpr + " )"
         OTHERWISE
   // cFilter  += FieldName( n ) + "
== " + cValToChar( uVal )
            cFilter  += oCol:cExpr + "
== " + cValToChar( uVal )
         ENDCASE
      ENDIF

   NEXT
   // ******************************
   // /
   // msginfo(cFilter)
   // msgGet( "
title", "message", @cFilter )

   IF Empty( cFilter )

      IF ! Empty( dbFilter() )
         dbClearFilter()
         oBrw:Refresh()
      ENDIF

   ELSE

      IF !( dbFilter() == cFilter )
         SET FILTER TO &cFilter
         GO TOP
         oBrw:Refresh()
      ENDIF

   ENDIF

   oBrw:SetFocus()

RETURN NIL

//
//   SETKEY( VK_F10, { | nKey | PROFILES() } )

FUNCTION PROFILES()

   ? [????????]

RETURN NIL

//   SETKEY( VK_F12, { | nKey | DBFTONEM() } )
FUNCTION DBFTONEM()

   ? [????????]

RETURN NIL

// FIN / END
João Santos - São Paulo - Brasil - Phone: +55(11)95150-7341
User avatar
karinha
 
Posts: 7872
Joined: Tue Dec 20, 2005 7:36 pm
Location: São Paulo - Brasil

Re: Focus error on this new project

Postby Marc Venken » Thu Dec 09, 2021 10:46 pm

The mouse is working ! Thans for your time and help..

I did some changes, a second browse for invoices (tab 2) tab 1 = customers..

This stuff normaly works great, but again, not oke now because of the windows that hide and show, ....

Could you get rid off the multy screen code (MDI) ? I don't need a screen to open 2x and stay open. Just 1 is ok, and that way I can handle them (normaly )))) )
I makes things more easy for my project.

Thanks.

Here the last code from you where I changed stuff.

Code: Select all  Expand view  RUN


// \SAMPLES\MARC2.PRG  - 09/12/2021 - Modified by: Joao - Version 1.2

#include "fivewin.ch"
#include "Directry.ch"
#include "inkey.ch"
#include 'ord.ch'
#include "ribbon.ch"
#include 'xbrowse.ch'

#define MY_GREEN   nRGB( 145, 214, 124)
#define MY_LIGHTGREEN nRGB( 236, 255, 224)
#define MY_LIGHTYELLOW nRGB( 255, 251, 142)
#define MY_LIGHTBLUE nRGB( 214, 229, 255)
#define MY_PAARS nRGB( 232, 201, 255)
#define MY_YELLOW nRGB( 255, 220, 96)

ANNOUNCE RDDSYS
REQUEST OrdKeyNo, OrdKeyCount, OrdCreate, OrdKeyGoto
REQUEST DBFCDX, DBFFPT

STATIC oWnd, oDlg
STATIC oDlgRB[ 3 ]
STATIC SERVER_PATH, LOCAL_PATH, oFld, CDRIVE, cLocal
STATIC lServer := .F.

FUNCTION Main()

   LOCAL sys_versie := "Dec 2021 - 02/12"
   LOCAL cErrorLogFileName := "MyLog.log"
   LOCAL oFol, oDlg, oRBar, oMenu, oMenuWnd, oBrush1, oGr, oGr1, oGr2, oGr3, ;
         oGr4, oSay1, oBmp, oFont1, oCursor, oBtn2, oBtn3, oBtn4
   LOCAL aBitmaps := { "..\bitmaps\alphabmp\facebook.bmp",;
                       "..\bitmaps\alphabmp\windows.bmp",;
                       "..\bitmaps\alphabmp\game.bmp",;
                       "..\bitmaps\alphabmp\viddler.bmp",;
                       "..\bitmaps\alphabmp\mail.bmp",;
                       "..\bitmaps\alphabmp\call.bmp",;
                       "..\bitmaps\alphabmp\settings2.bmp",;
                       "..\bitmaps\alphabmp\exit.bmp" }

   RDDSETDEFAULT("DBFCDX")

   SET CENTURY ON
   SET DATE BRITISH
   SET TIME FORMAT TO "HH:MM:SS"
   SET EPOCH TO YEAR( DATE() ) - 30
   SET SOFTSEEK OFF
   SET WRAP ON
   SETCANCEL( .F. )
   SET CONFIRM OFF
   SET DELETED ON
   SET _3DLOOK ON
   SET UNIQUE OFF
   SET ESCAPE OFF
   SET EXACT ON
   SET EXCLUSIVE OFF
   SET MULTIPLE OFF

   SERVER_PATH := "\\CAROLIEN-PC\MARC\"
   //LOCAL_PATH  := CURDRIVE()+"
:\MARC\"
   LOCAL_PATH  := CURDRIVE()+"
:\fwharb\samples\"

   cDrive      := "
C:\MARC\"                     // DEZE MOET
   cLocal      := "
C:\MARC\"                     // DEZE MOET

   If .NOT. lIsDir( LOCAL_PATH )

      LMkdir( LOCAL_PATH )

   Endif

   FW_SetUnicode( .T. )

   SetBalloon( .T. ) // Balloon shape required for tooltips

   SkinButtons()

   SetGetColorFocus( MY_LIGHTGREEN )

   SETKEY( VK_F10, { | nKey | PROFILES() } )
   SETKEY( VK_F12, { | nKey | DBFTONEN() } ) //??

   xbrNumFormat( "
E", .T. )  // "E" for European, "A" for American and others // .t. for showing thousand separators

   MENU oMenu 2007
      // ??
   ENDMENU

   DEFINE FONT oFont1 NAME "
Arial" SIZE 0, - 15 // BOLD

   DEFINE CURSOR oCursor HAND
   DEFINE BRUSH oBrush1 COLOR nRGB( 223, 233, 244 )

   DEFINE WINDOW oWnd TITLE "
Maveco Bedrijfskleding " + FWVERSION ;
      FROM 0, 0 TO 1030, 1920 pixel MDI MENU oMenu BRUSH oBrush1

   DEFINE RIBBONBAR oRBar WINDOW oWnd PROMPT "
Klanten", "Leveranciers", "Ingeven Documenten";
      HEIGHT 130 TOPMARGIN 25

   // "
Marc, enter the data from folders. oFld:aDialogs[ 2, 3, 4, ETC. ]"


   //Marc_FolderEx( oWnd ) // new:

   // Marc has moved this so that there is a start screen.  From the startscreen hit Customers to start folder

   ADD GROUP oGr  RIBBON oRBar TO OPTION 1 PROMPT "
Clipboard" width 130 ;
      BITMAP "
..\bitmap\fivetech.BMP"

   @ 02, 05 ADD BUTTON oBtn2 GROUP oGr BITMAP "
bitmaps\cut16.BMP" ;
      SIZE 75, 20 PROMPT "
Customers"  MOSTLEFT round ;
      action ( Marc_FolderEx(oWnd) )

   @ 24, 05 ADD BUTTON oBtn3 GROUP oGr BITMAP "
bitmaps\copy16.BMP" ;
      SIZE 75, 20 PROMPT "
Brands"  MOSTLEFT round;
      action ( Marc_FolderEx(oFld) )

   @ 46, 05 ADD BUTTON oBtn4 GROUP oGr BITMAP "
bitmaps\paste16.BMP" ;
      SIZE 75, 20 PROMPT "
Statistics"  MOSTLEFT round

   ADD GROUP oGr2 RIBBON oRBar TO OPTION 1 PROMPT "
Exit" width 70 ;
      BITMAP "
bitmap\fivetech.bmp"

   @ 15, 20 ADD BUTTON oBtn4 GROUP oGr2 BITMAP "
bitmaps\32x32\quit.BMP" ;
      SIZE 34, 52 PROMPT "
Exit" action( oWnd:End() )

   SET MESSAGE OF oWnd TO "
Version : " + sys_versie ;
      CENTERED CLOCK KEYBOARD 2007

   WndCenter( oWnd:hWnd )

   ACTIVATE WINDOW oWnd MAXIMIZED


   oBrush1:End()
   oRBar:End()

RETURN NIL

FUNCTION Marc_FolderEx( oWnd )

   LOCAL oWndChild, i, oFont1
   LOCAL aBitmaps := { "
..\bitmaps\alphabmp\facebook.bmp",;
                       "
..\bitmaps\alphabmp\windows.bmp",;
                       "
..\bitmaps\alphabmp\game.bmp",;
                       "
..\bitmaps\alphabmp\viddler.bmp",;
                       "
..\bitmaps\alphabmp\mail.bmp",;
                       "
..\bitmaps\alphabmp\call.bmp",;
                       "
..\bitmaps\alphabmp\settings2.bmp",;
                       "
..\bitmaps\alphabmp\exit.bmp" }

   DEFINE FONT oFont1 NAME "
Arial" SIZE 0, - 15 // BOLD

   DEFINE WINDOW oWndChild MDICHILD TITLE "
TFolderex - Testing -"

    @ 3, 3 FOLDEREX oFld PIXEL ADJUST ROUND 5                                 ;
       PROMPT "
Basis", "Documenten", "Personen", "Facturen", "Statistics"     ;
       BITMAPS "
..\bitmaps\alphabmp\Facebook.bmp",                            ;
               "
..\bitmaps\alphabmp\myspace.bmp",                             ;
               "
..\bitmaps\alphabmp\Twitter.bmp",                             ;
               "
..\bitmaps\alphabmp\mail.bmp",;
               "
..\bitmaps\alphabmp\viddler.bmp",;

   oFld:aEnable = { .T., .T., .T., .T., .F. }
   oFld:SetOption( 1 )
   oFld:Show()

   OpenDatabases()

   Dialog01( oFld )      // ACTION IN DIALOG OF FOLDER 01

   Dialog_Marc02( oFld ) // ACTION IN DIALOG OF FOLEDR 02

   Dialog_Marc03( oFld ) // ACTION IN DIALOG OF FOLEDR 03

   Dialog_Marc04( oFld ) // ACTION IN DIALOG OF FOLEDR 04

   SET FONT OF oFld  TO oFont1

   ACTIVATE WINDOW oWndChild MAXIMIZED CENTERED

RETURN NIL

FUNCTION Dialog_Marc02( oFld )
   LOCAL oFont1, oBold, oFont, oFont3, oFontS, oFontXS
   LOCAL aCoords := GetCoors( oWnd:oWndClient ), oBrush, oGet
   LOCAL sys_klant := Space( 10 ), nWild := 1
   LOCAL oBmpAlpha
   LOCAL lEscapa := .F.
   LOCAL oBrw[ 2 ], aVelden2 := {}, cCol
   LOCAL hBmp := ReadBitmap( 0, "
bitmaps\search.bmp" )


   HideDlg( 2 )

   IF ValType( oDlgRB[ 2 ] ) <> "
O"

      DEFINE FONT oFont1 NAME "
Ms Sans Serif" SIZE 0, - 8 BOLD
      DEFINE FONT oBold NAME 'CALIBRI' SIZE 0, - 12 BOLD
      DEFINE FONT oFont NAME "
CALIBRI" SIZE 0, - 14
      DEFINE FONT oFont3 NAME "
Segoe UI" SIZE 0, - 12
      DEFINE FONT oFontS NAME "
Segoe UI" SIZE 0, - 09
      DEFINE FONT oFontXS NAME "
Segoe UI" SIZE 0, - 08

      DEFINE BRUSH oBrush FILE "
Bitmaps\BackGrnd\Stone.bmp"

      DEFINE DIALOG oDlgRB[ 2 ] FROM 0, 0 TO 700, 1900 OF oFld:aDialogs[ 2 ] PIXEL COLORS RGB( 0, 0, 0 ), RGB( 255, 255, 255 )

      oDlgRB[ 2 ]:nStyle := nOR( WS_CHILD ) // ,WS_THICKFRAME

      aVelden2 :=  { ;
         { "
invnum", "Invoice", NIL,  90 }, ;
         { "
date", "Date", NIL,  150 }, ;
         { "
Client", "Name", NIL, 300 },;
         { "
Total", "Total", NIL, 150 },;
         { "
Paydate", "Paydate", NIL, 150 }}

      @ 0, 0 XBROWSE oBrw[ 2 ] size - 05, - 20 PIXEL OF oDlgRB[ 2 ] font oFont ;
         DATASOURCE "
invoices" ;
         COLUMNS aVelden2 ;
         AUTOSORT CELL LINES NOBORDER FOOTERS

      oBrw[ 2 ]:SetChecks()
      oBrw[ 2 ]:nStretchCol         := STRETCHCOL_WIDEST

      oBrw[ 2 ]:lHScroll := .F.
      oBrw[ 2 ]:nHeadStrAligns  := AL_CENTER

      FOR EACH cCol in { "
Paydate" }
         WITH OBJECT oBrw[ 2 ]:oCol( cCol )
            :nEditType     := EDIT_GET
            :bClrHeader    := {|| { CLR_GREEN, 155 } }
         END
      NEXT

      // Search GETBAR
      oBrw[ 2 ]:lGetBar   := .T.

      FOR EACH cCol in { "
Invoice", "Date", "Name", "Total" }

         WITH OBJECT oBrw[ 2 ]:oCol( cCol )

            :uBarGetVal    := uValBlank( :Value )
            :cBarGetPic    := :cEditPicture
            :bClrEdit      := {|| { CLR_BLACK, MY_LIGHTYELLOW } }

            :lBarGetOnKey := .T. // after having setfocus the oBrowse object, the end user can insert the characters directly into the get
            :cBarGetBmp := hBmp // this for show the Bitmap on the get
            :bBarGetAction := {|| ( oBrw[ 2 ]:cAlias )->( MARC_SETFILTER( oBrw[ 2 ] ) ) } // this for show the bitmap on the get and associated a action

         END

      NEXT

      WITH OBJECT oBrw[ 2 ]

         :lColChangeNotify := .T.
         :lFooter          := .T.
         :bRecSelHeader    := {|| "
Invoice" }
         :bRecSelData      := {| o | o:KeyNo }
         :bRecSelFooter    := {| o | o:nLen }
         :oRecSelFont      := oFont3  // optional
         :nRecSelWidth     := "
99999" // required size
         :lHScroll      := .F.
         :lMultiSelect     := .T.

         //:bLDClickDatas := {|| msginfo( "
Enter" )  }

         :nColDividerStyle := LINESTYLE_LIGHTGRAY
         :nRowDividerStyle := LINESTYLE_LIGHTGRAY
         :bClrRowFocus     := {|| { CLR_BLACK, RGB( 185, 220, 255 ) } }
         :nMarqueeStyle    := MARQSTYLE_HIGHLROWMS

         :bClrSelFocus = {|| { CLR_WHITE, RGB( 0, 128, 128 ) } } // CUANDO TIENE EL FOCUS

         :oHeaderFonts     := oBold

         :bKeyDown   := {| k | IF ( K == VK_DELETE, Del_row( oBrw[ 2 ] ), NIL ) }

      END

      oBrw[ 2 ]:CreateFromCode()
      oBrw[ 2 ]:setfocus()

      ACTIVATE DIALOG oDlgRB[ 2 ] NOWAIT ;
         ON INIT ( oDlgRB[ 2 ]:Move( aCoords[ 1 ] + 0, aCoords[ 2 ] + 0,,, .T. ) );
         VALID lEscapa

      oFont1:End()
      oBold:End()
      oFont:End()
      oFont3:End()
      oFontS:End()
      oFontXS:End()

   ELSE

      oDlgRB[ 2 ]:Show()

   ENDIF

RETURN NIL

FUNCTION Dialog_Marc03( oFld )

   @ 3,10 FOLDEREX OF oFld:aDialogs[ 3 ] PIXEL SIZE 450, 190 ;

RETURN NIL

FUNCTION Dialog_Marc04( oFld )

   @ 3,10 FOLDEREX OF oFld:aDialogs[ 4 ] PIXEL SIZE 450, 190 ;

RETURN NIL

FUNCTION Dialog01( oFld )

   LOCAL oFont1, oBold, oFont, oFont3, oFontS, oFontXS
   LOCAL aCoords := GetCoors( oWnd:oWndClient ), oBrush, oGet
   LOCAL sys_klant := Space( 10 ), nWild := 1
   LOCAL oBmpAlpha
   LOCAL lEscapa := .F.
   LOCAL oBrw[ 1 ], aVelden := {}, cCol
   LOCAL hBmp := ReadBitmap( 0, "
bitmaps\search.bmp" )


   HideDlg( 1 )

   IF ValType( oDlgRB[ 1 ] ) <> "
O"

      DEFINE FONT oFont1 NAME "
Ms Sans Serif" SIZE 0, - 8 BOLD
      DEFINE FONT oBold NAME 'CALIBRI' SIZE 0, - 12 BOLD
      DEFINE FONT oFont NAME "
CALIBRI" SIZE 0, - 14
      DEFINE FONT oFont3 NAME "
Segoe UI" SIZE 0, - 12
      DEFINE FONT oFontS NAME "
Segoe UI" SIZE 0, - 09
      DEFINE FONT oFontXS NAME "
Segoe UI" SIZE 0, - 08

      DEFINE BRUSH oBrush FILE "
Bitmaps\BackGrnd\Stone.bmp"

      DEFINE DIALOG oDlgRB[ 1 ] FROM 0, 0 TO 700, 1900 OF oFld:aDialogs[ 1 ] PIXEL COLORS RGB( 0, 0, 0 ), RGB( 255, 255, 255 )

      oDlgRB[ 1 ]:nStyle := nOR( WS_CHILD ) // ,WS_THICKFRAME

      aVelden :=  { ;
         { "
ID", "ID", NIL,  90 }, ;
         { "
First", "First", NIL,  350 }, ;
         { "
Last", "Last", NIL, 300 }, ;
         { "
Street", "Street", NIL, 300 }, ;
         { "
City", "City", NIL, 200 }, ;
         { "
Zip", "Zip", NIL, 150 } }

      @ 0, 0 XBROWSE oBrw[ 1 ] size - 05, - 20 PIXEL OF oDlgRB[ 1 ] font oFont ;
         DATASOURCE "
customer" ;
         COLUMNS aVelden ;
         AUTOSORT CELL LINES NOBORDER FOOTERS

      oBrw[ 1 ]:SetChecks()
      oBrw[ 1 ]:nStretchCol         := STRETCHCOL_WIDEST

      oBrw[ 1 ]:lHScroll := .F.
      oBrw[ 1 ]:nHeadStrAligns  := AL_CENTER

      FOR EACH cCol in { "
First", "Last", "Street" }
         WITH OBJECT oBrw[ 1 ]:oCol( cCol )
            :nEditType     := EDIT_GET
            :bClrHeader    := {|| { CLR_GREEN, 155 } }
         END
      NEXT

      // Search GETBAR
      oBrw[ 1 ]:lGetBar   := .T.

      FOR EACH cCol in { "
First", "Last", "Street", "City", "Zip" }

         WITH OBJECT oBrw[ 1 ]:oCol( cCol )

            :uBarGetVal    := uValBlank( :Value )
            :cBarGetPic    := :cEditPicture
            :bClrEdit      := {|| { CLR_BLACK, MY_LIGHTYELLOW } }

            :lBarGetOnKey := .T. // after having setfocus the oBrowse object, the end user can insert the characters directly into the get
            :cBarGetBmp := hBmp // this for show the Bitmap on the get
            :bBarGetAction := {|| ( oBrw[ 1 ]:cAlias )->( MARC_SETFILTER( oBrw[ 1 ] ) ) } // this for show the bitmap on the get and associated a action

         END

      NEXT

      WITH OBJECT oBrw[ 1 ]

         :lColChangeNotify := .T.
         :lFooter          := .T.
         :bRecSelHeader    := {|| "
Klant" }
         :bRecSelData      := {| o | o:KeyNo }
         :bRecSelFooter    := {| o | o:nLen }
         :oRecSelFont      := oFont3  // optional
         :nRecSelWidth     := "
99999" // required size
         :lHScroll      := .F.
         :lMultiSelect     := .T.

         //:bLDClickDatas := {|| msginfo( "
Enter" )  }

         :nColDividerStyle := LINESTYLE_LIGHTGRAY
         :nRowDividerStyle := LINESTYLE_LIGHTGRAY
         :bClrRowFocus     := {|| { CLR_BLACK, RGB( 185, 220, 255 ) } }
         :nMarqueeStyle    := MARQSTYLE_HIGHLROWMS

         :bClrSelFocus = {|| { CLR_WHITE, RGB( 0, 128, 128 ) } } // CUANDO TIENE EL FOCUS

         :oHeaderFonts     := oBold

         :bKeyDown   := {| k | IF ( K == VK_DELETE, Del_row( oBrw[ 1 ] ), NIL ) }

      END

      oBrw[ 1 ]:CreateFromCode()
      oBrw[ 1 ]:setfocus()

      ACTIVATE DIALOG oDlgRB[ 1 ] NOWAIT ;
         ON INIT ( oDlgRB[ 1 ]:Move( aCoords[ 1 ] + 0, aCoords[ 2 ] + 0,,, .T. ) );
         VALID lEscapa

      oFont1:End()
      oBold:End()
      oFont:End()
      oFont3:End()
      oFontS:End()
      oFontXS:End()

   ELSE

      oDlgRB[ 1 ]:Show()

   ENDIF

RETURN NIL

FUNCTION HideDlg( nDlg )

   LOCAL i := 1

   FOR i := 1 TO Len( oDlgRB )

      IF ValType( oDlgRB[ i ] ) == "
O"
         oDlgRB[ i ]:Hide()
      ENDIF

   NEXT

   RETURN NIL

FUNCTION MyErrorAction( cErrorLogFileName, oError )

   LOCAL cErrScreen := "
"

   MsgInfo( "
Er is een fout opgetreden in het programma.  Gelieve het programma opnieuw te starten" )

RETURN NIL

FUNCTION lookup_klant( cKlant )

   msginfo( cKlant )

RETURN NIL

FUNCTION dbftonen() // ??

   LOCAL n, j, nTarget
   LOCAL cErrorlog := "
"

   cErrorLog += CRLF + "
DataBases in use" + CRLF + "================" + CRLF

   FOR n = 1 TO 255

      IF ! Empty( Alias( n ) )

         cErrorLog += CRLF + Str( n, 3 ) + "
: " + If( Select() == n, "=> ", "   " ) + ;
            ( Alias( n ) )->( dbInfo( DBI_FULLPATH ) ) + Space( 2 ) + "
RddName: " + ;
            ( Alias( n ) )->( rddName() ) + CRLF
         cErrorLog += "
    =======================================================" + CRLF
         cErrorLog += "
    RecNo    RecCount    BOF   EOF" + CRLF
         cErrorLog += "
  " + Transform( ( Alias( n ) )->( RecNo() ), "9999999" ) + ;
            "
    " + Transform( ( Alias( n ) )->( RecCount() ), "9999999" ) + ;
            "
   " + cValToChar( ( Alias( n ) )->( Bof() ) ) + ;
            "
  " + cValToChar( ( Alias( n ) )->( Eof() ) ) + Transform( ( Alias( n ) )->( ordKeyCount() ), "9999999" )  + CRLF + CRLF

         IF ( Alias( n ) )->( rddName() ) != "
ARRAYRDD"
            cErrorLog += "
    Indexes in use " + Space( 23 ) + "TagName" + CRLF + CRLF
            FOR j = 1 TO 25
               IF ! Empty( ( Alias( n ) )->( IndexKey( j ) ) )
                  cErrorLog += Space( 8 ) + ;
                     If( ( Alias( n ) )->( IndexOrd() ) == j, "
=> ", "   " ) + ;
                     PadR( ( Alias( n ) )->( IndexKey( j ) ), 35 ) + ;
                     ( Alias( n ) )->( ordName( j ) ) + ;
                     CRLF
               ENDIF
            NEXT
            cErrorLog += CRLF + "
    Relations in use" + CRLF + CRLF
            FOR j = 1 TO 8
               IF ! Empty( ( nTarget := ( Alias( n ) )->( dbRSelect( j ) ) ) )
                  cErrorLog += Space( 3 ) + Str( j ) + "
: " + ;
                     "
TO " + ( Alias( n ) )->( dbRelation( j ) ) + ;
                     "
INTO " + Alias( nTarget ) + CRLF
                  // uValue = ( Alias( n ) )->( DbRelation( j ) )
                  // cErrorLog += cValToChar( ordsetfocus( uValue ) ) + CRLF
               ENDIF
            NEXT

         ENDIF
      ENDIF
   NEXT

   MemoEdit( @cErrorlog, "
Geopende Databases", 10, 60, 60, 150 )

RETURN NIL

FUNCTION Popfiles()

   LOCAL oDlgpop, oBar, oBtnSave, oBold, oFont, oFontBig, oBrush

   SET 3DLOOK ON

   DEFINE BRUSH oBrush STYLE TILED

   DEFINE FONT oBold    NAME 'CALIBRI' SIZE 0, -12 BOLD
   DEFINE FONT oFont    NAME "
CALIBRI" SIZE 0, -14
   DEFINE FONT oFontBig NAME "
CALIBRI" SIZE 0, -24

   DEFINE DIALOG oDlgpop SIZE 200, 100 PIXEL TRUEPIXEL ;
      TITLE "
Klantenbestand : "                        ;
      GRADIENT { { 1, nRGB( 125, 155, 175 ), nRGB( 125, 155, 175 ) } }

   DEFINE BUTTONBAR oBar OF oDlgpop SIZE 45, 45 2007

   DEFINE BUTTON oBtnSave OF oBar FILE "
bitmaps\save.bmp" PROMPT "Data"  ;
      GROUP TOOLTIP "
Gegevens" ;
      ACTION popopenfile()

   DEFINE BUTTON OF oBar FILE "
bitmaps\print.bmp" PROMPT "Struct" ;
      TOOLTIP "
Structure" ;
      ACTION popopenstruc()

   ACTIVATE DIALOG oDlgpop

   oBrush:End()
   oBold:End()
   oFont:End()
   oFontBig:End()

RETURN NIL

FUNCTION popopenfile()

   LOCAL oBrw, cFile, aStruc

   IF .NOT. Empty( cFile := cGetFile(   "
DataFile (*.DBF)|*.dbf|",          ;
         "
Select Data File to Browse", 1,     ;
         "
\programmas\fotoselect" ) )

      USE &cFile ALIAS datastruc NEW

      aStruc := dbStruct()

      xbrowser( "
datastruc" ) SHOW RECID FASTEDIT AUTOSORT ;
         SETUP ( oBrw:lIncrFilter := .T., oBrw:lSeekWild := .T. )

      CLOSE datastruc

   ENDIF

RETURN NIL

FUNCTION popopenstruc()

   LOCAL cFile
   LOCAL aStruc

   IF .NOT. Empty( cFile := cGetFile(   "
DataFile (*.DBF)|*.dbf|",          ;
         "
Select Data File to Browse", 1,     ;
         "
\programmas\fotoselect" ) )

      USE &cFile ALIAS DATASTRUC NEW SHARED

      aStruc := datastruc->( dbStruct() )

      xbrowser( aStruc )

      CLOSE datastruc

   ENDIF

RETURN NIL

FUNCTION NETOPEN( cFile, cIndex, lMode, cAlias, nSeconds, lNewArea, cDriver, ;
                  lReadOnly )

   LOCAL nWaitTime, lContinue := .T., lSuccess := .F., TSEL := 0

   DEFAULT lMode     :=  .T.                     // shared mode
   DEFAULT cIndex := "
"
   DEFAULT nSeconds  :=  3
   DEFAULT cAlias    := cFile
   DEFAULT lNewArea  :=  .T.
   DEFAULT cDriver   := "
DBFCDX"
   DEFAULT lReadOnly :=  .F.

   SET DEFAULT TO LOCAL_PATH

   nWaitTime := nSeconds

   cFile := AllTrim( cFile ) + "
.dbf"

   IF lServer

      cFile := server_path + cFile

      IF .NOT. FILE( cFile )

         MsgInfo( "
Database not created correctly.", "Attention" )

         RETURN( .F. )

      ENDIF

   ELSE

      cFile := local_path + cFile

      IF .NOT. FILE( cFile )

         MsgInfo( "
Database not created correctly. "+cFile, "Attention" )

         RETURN( .F. )

      ENDIF

   ENDIF

   // bestand het bestand
   IF ! File( cFile )

      Exit( "
Bestand " + CFILE + ".DBF is afwezig" )

   ENDIF

   // verify driver is valid
   IF AScan( rddList(), cDriver ) == 0

      MSGSTOP( "
Driver " + Cdriver + "  afwezig" )

      Exit()

   ENDIF

   // Indien reeds geopend, alles ok, select waar
   IF Select( cAlias ) # 0

      MsgInfo( "
File : " + cAlias + " is reeds geopend" )

      TSEL := Select( cAlias )

      Select( TSEL )

      lContinue := .T.
      lNewArea  := .F.

   ENDIF

   // while continuing to attempt open
   WHILE lContinue // while .not. timed-out

      SYSREFRESH()

      WHILE nSeconds > 0 .AND. lContinue

         SYSREFRESH()

         // dbUseArea( lNewArea, cDriver, cFile, cAlias, ( .not. lMode ), lReadOnly )
         dbUseArea( lNewArea, cDriver, cFile, cAlias, lMode, lReadOnly )

         // check for success/failure
         IF NetErr()
            nSeconds--
            lSuccess  := .F.
         ELSE
            // open successful
            nSeconds  := 0
            lSuccess  := .T.
            lContinue := .F.
         ENDIF

      ENDDO

      IF .NOT. lSuccess

         nSeconds  := nWaitTime

         MSGSTOP( "
Bestand " + CFILE + " Alias : " + cAlias + " is geopend door een andere gebruiker" + CRLF + CRLF + "Gelieve even te wachten" )

         lSuccess  := .F.
         lContinue := .T.
         lNewArea  := .T.

      ENDIF

      IF !Empty( cIndex )

         &cAlias->( dbSetOrder( cIndex ) )

      ENDIF

   ENDDO

RETURN lSuccess

CLASS TSeek STATIC

   DATA oBrw

   METHOD New( oBrw ) CONSTRUCTOR
   METHOD SetText( c ) INLINE ::oBrw:RefreshFooters()

ENDCLASS

METHOD New( oBrw ) CLASS TSeek

   ::oBrw   := oBrw

RETURN Self

FUNCTION del_row( oBrw )

   IF MsgYesNo( "
Deze regel wissen" )

      oBrw:delete()

   ENDIF

RETURN NIL

FUNCTION Exit( cErrInfo )

   cErrInfo += CRLF + "
Gelieve deze fout te melden" + CRLF + CRLF + ;
                      "
Het Programma zal nu eindigen"

   CLOSE ALL

   MSGSTOP( cErrInfo )

   SET RESOURCES TO

   ErrorLevel( 1 )

   DbCommitAll()
   DbUnLockAll()
   DbCloseAll()
   FreeResources()
   Release All
   SysRefresh()
   HB_GCALL( .T. )

   CLEAR MEMORY

   PostQuitMessage( 0 )

   QUIT

RETURN NIL

FUNCTION MARC_SETFILTER( oBrw ) // SETFILTER()?? INTERN COMMAND.

   LOCAL cFilter := "
"
   LOCAL n, oCol, uVal, cType

   FOR n := 1 TO Len( oBrw:aCols )

      oCol  := oBrw:aCols[ n ]

      IF ! Empty( uVal := oCol:uBarGetVal )

         IF !Empty( cFilter )
            cFilter  += "
.AND. "
         ENDIF

         cType    := ValType( uVal )

         DO CASE
         CASE cType == 'C'
            uVal     := Upper( AllTrim( uVal ) )
   // cFilter += '"
' + uVal + '" $ UPPER( ' + FieldName( n ) + " )"
            cFilter += '"
' + uVal + '" $ UPPER( ' + oCol:CExpr + " )"
         OTHERWISE
   // cFilter  += FieldName( n ) + "
== " + cValToChar( uVal )
            cFilter  += oCol:cExpr + "
== " + cValToChar( uVal )
         ENDCASE
      ENDIF

   NEXT
   // ******************************
   // /
   // msginfo(cFilter)
   // msgGet( "
title", "message", @cFilter )

   IF Empty( cFilter )

      IF ! Empty( dbFilter() )
         dbClearFilter()
         oBrw:Refresh()
      ENDIF

   ELSE

      IF !( dbFilter() == cFilter )
         SET FILTER TO &cFilter
         GO TOP
         oBrw:Refresh()
      ENDIF

   ENDIF

   oBrw:SetFocus()

RETURN NIL

//
//   SETKEY( VK_F10, { | nKey | PROFILES() } )

FUNCTION PROFILES()

   ? [????????]

RETURN NIL

//   SETKEY( VK_F12, { | nKey | DBFTONEM() } )
FUNCTION DBFTONEM()

   ? [????????]

RETURN NIL

function opendatabases()
  //  Index creation will be done only once in real program !
  netopen( "
customer", "last" )
  customer->(FW_CdxCreate())

  netopen( "
invoices", "code" )
  invoices->(FW_CdxCreate())

  //  Set relation so only invoices from selected will be seen
  // set relation to customer->first into invoices scoped

//  Set relation to

return NIL

// FIN / END


Marc Venken
Using: FWH 23.04 with Harbour
User avatar
Marc Venken
 
Posts: 1456
Joined: Tue Jun 14, 2016 7:51 am
Location: Belgium

Re: Focus error on this new project

Postby karinha » Fri Dec 10, 2021 1:05 pm

João Santos - São Paulo - Brasil - Phone: +55(11)95150-7341
User avatar
karinha
 
Posts: 7872
Joined: Tue Dec 20, 2005 7:36 pm
Location: São Paulo - Brasil

Re: Focus error on this new project

Postby Marc Venken » Fri Dec 10, 2021 1:16 pm

Hey,

Oeps...

I changed the cPath parameter in the program to my location. This should be commend(//) and yours Should be back to your location on your pc
Marc Venken
Using: FWH 23.04 with Harbour
User avatar
Marc Venken
 
Posts: 1456
Joined: Tue Jun 14, 2016 7:51 am
Location: Belgium

Re: Focus error on this new project

Postby karinha » Fri Dec 10, 2021 2:30 pm

Marc, using DIALOG on Folder:

https://imgur.com/PthIMVG

Image

Regards.
João Santos - São Paulo - Brasil - Phone: +55(11)95150-7341
User avatar
karinha
 
Posts: 7872
Joined: Tue Dec 20, 2005 7:36 pm
Location: São Paulo - Brasil

Re: Focus error on this new project

Postby karinha » Fri Dec 10, 2021 2:38 pm

Marc, continue...

Code: Select all  Expand view  RUN

#Define CLR_LGREEN     nRGB( 190, 215, 190 )
#Define CLR_SOFTYELLOW nRGB( 255, 251, 225 )
#Define CLR_PINK       nRGB( 255, 128, 128 )
#Define CLR_NBLUE      nRGB( 128, 128, 192 )
#Define CLR_MSPURPLE   nRGB( 0,   120, 215 )
#Define CLR_MSRED      nRGB( 232,  17,  35 )
#Define CLR_MSGRAY     nRGB( 229, 229, 229 )

FUNCTION Marc_FolderEx( oWnd )

   LOCAL oDlg, oFld, oBarDialog, oFont, cTitle, aGrad, oOk, oExit, oFont1
   LOCAL cDenominazione := "I LOVE FIVEWIN THE BEST OF THE WORLD!            "
   LOCAL cIndirizzo     := "AVENUE ATLANTICA, 1200 - LEBLON - RIO DE JANEIRO."
   LOCAL oSay      := ARRAY(4)
   LOCAL aGet      := ARRAY(4)
   LOCA  cCompl    := REPLICATE( ".",  9 )
   LOCAL SilDrawLi := REPLICATE( "_", 13 )
   LOCAL EmailSilv := SPACE(50)

   OpenDatabases()

   cTitle := "Marc Informatica Corporation: Systems Folders"

   SET _3DLOOK ON

   SetGetColorFocus( CLR_LGREEN ) // COR EM TODOS OS GETS DOS DIALOGOS.

   tGet():lDisColors  := .F.   // WHEN( .F. ) COR.
   tGet():nClrTextDis := CLR_HBLUE
   tGet():nClrPaneDis := CLR_SOFTYELLOW

   SetBalloon( .T. ) // Balloon shape required for tooltips

   SkinButtons()

   aGrad := { { 1, CLR_WHITE, CLR_HCYAN  } }

   DEFINE FONT oFont NAME 'Tahoma' SIZE 0, - 20

   DEFINE DIALOG oDlg TITLE cTitle SIZE 1240, 450 PIXEL TRUEPIXEL            ;
      GRADIENT aGrad

   oDlg:lHelpIcon := .F.

   DEFINE BUTTONBAR oBarDialog OF oDlg SIZE 80, 80 2007 BOTTOM NOBORDER

   @ 3, 3 FOLDEREX oFld SIZE oDlg:nWidth, oDlg:nHeight - oBarDialog:nheight  ;
      PROMPT "Basis", "Documenten", "Personen", "Facturen", "Statistics",    ;
             "Folder 6", "Folder 7", "Folder 8", "Folder 9",  "Folder 10"    ;
      BITMAPS "..\bitmaps\alphabmp\Facebook.bmp",                            ;
              "..\bitmaps\alphabmp\myspace.bmp",                             ;
              "..\bitmaps\alphabmp\Twitter.bmp",                             ;
              "..\bitmaps\alphabmp\mail.bmp",                                ;
              "..\bitmaps\alphabmp\viddler.bmp"                              ;
      FONT oFont PIXEL COLOR CLR_MSGRAY TAB HEIGHT 25 ROUND 5

   oFld:aEnable = { .T., .T., .T., .T., .T., .F., .F., .F., .F., .F. }
   oFld:SetOption( 1 )
   oFld:Show()

   // Marc, write the code here on the spot.

   // example:

// @ 39.50, 10 SAY oSilDrawLi VAR SilDrawLi SIZE 150, 15 OF oFld:aDialogs[1] ;
//    UPDATE PIXEL FONT oFont COLORS CLR_MSPURPLE, CLR_WHITE TRANSPARENT

   // folder 2

   // folder 3

   // etc

   @ 385, 440 BUTTON oOk   PROMPT "Send &Marc" SIZE 120, 30 OF oDlg PIXEL    ;
      ACTION( oDlg:End() )

   @ 385, 590 BUTTON oExit PROMPT "&Exit"      SIZE 120, 30 OF oDlg PIXEL       ;
      ACTION( oDlg:End() ) DEFAULT CANCEL

   SET FONT OF oOk   TO oFont
   SET FONT OF oExit TO oFont

   ACTIVATE DIALOG oDlg CENTERED


   IF Set( _SET_INSERT, ! Set( _SET_INSERT ) )
      Set( _SET_INSERT, ! Set( _SET_INSERT ) )
   ENDIF

   oFont:End()

RETURN NIL
 


Regards, saludos.
João Santos - São Paulo - Brasil - Phone: +55(11)95150-7341
User avatar
karinha
 
Posts: 7872
Joined: Tue Dec 20, 2005 7:36 pm
Location: São Paulo - Brasil

Next

Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: No registered users and 71 guests