Page 1 of 1

Error with TclipGet

Posted: Tue Nov 06, 2012 8:45 am
by Eoeo
On a dialog I have some gets and 12 checkboxes ( I made the dialog with @x,y no resources because win7 leak memory)

The problem : If the user click before on one checkbox NOT allways it make a TclipGet Error

The Error.log

Code: Select all


Application
===========
   Path and name: C:\work\PRG\Family\main.Exe (32 bits)
   Size: 3,825,664 bytes
   Compiler version: xHarbour build 1.2.1 Intl. (SimpLex) (Rev. 6715)
   FiveWin  Version: FWHX 12.03
   Windows version: 5.1, Build 2600 Service Pack 2

   Time from start: 0 hours 1 mins 44 secs 
   Error occurred at: 06-11-2012, 09:41:00
   Error description: Error BASE/1068  Argument error: array access
   Args:
     [   1] = N   1
     [   2] = N   1

Stack Calls
===========
   Called from: source\rtl\tget.prg => TCLIPGET:UNTRANSFORM( 1122 )
   Called from: source\rtl\tget.prg => TCLIPGET:ASSIGN( 545 )
   Called from: .\source\classes\TGET.PRG => TGET:LVALID( 1182 )
   Called from: .\source\classes\CONTROL.PRG => TGET:FWLOSTFOCUS( 1110 )
   Called from: .\source\classes\CONTROL.PRG => TCONTROL:HANDLEEVENT( 1675 )
   Called from: .\source\classes\TGET.PRG => TGET:HANDLEEVENT( 579 )
   Called from: .\source\classes\WINDOW.PRG => _FWH( 3153 )
   Called from:  => DIALOGBOXINDIRECT( 0 )
   Called from: .\source\classes\DIALOG.PRG => TDIALOG:ACTIVATE( 270 )
   Called from: .\source\function\ERRSYSW.PRG => ERRORDIALOG( 426 )
   Called from: .\source\function\ERRSYSW.PRG => (b)ERRORSYS( 31 )
   Called from: .\source\classes\TGET.PRG => TGET:LOSTFOCUS( 1200 )
   Called from: .\source\classes\CONTROL.PRG => TGET:KILLFOCUS( 1055 )
   Called from: .\source\classes\CONTROL.PRG => TCONTROL:HANDLEEVENT( 1663 )
   Called from: .\source\classes\TGET.PRG => TGET:HANDLEEVENT( 579 )
   Called from: .\source\classes\WINDOW.PRG => _FWH( 3153 )
   Called from:  => DIALOGBOXINDIRECT( 0 )
   Called from: .\source\classes\DIALOG.PRG => TDIALOG:ACTIVATE( 270 )
   Called from: source\PPeriodici.prg => PEEDITA( 900 )
   Called from: source\PPeriodici.prg => (b)PERIODICI( 218 )
   Called from: Lib\vtaskbar\VMenu.prg => TVMENU:EVALACTION( 1700 )
   Called from: Lib\vtaskbar\VMenu.prg => TVMENU:LBUTTONUP( 1398 )
   Called from: .\source\classes\CONTROL.PRG => TCONTROL:HANDLEEVENT( 1690 )
   Called from: Lib\vtaskbar\VMenu.prg => TVMENU:HANDLEEVENT( 905 )
   Called from: .\source\classes\WINDOW.PRG => _FWH( 3153 )
   Called from:  => WINRUN( 0 )
   Called from: .\source\classes\WINDOW.PRG => TWINDOW:ACTIVATE( 980 )
   Called from: source\main.prg => TAPPLICATION:ACTIVATE( 348 )
   Called from: source\main.prg => MAIN( 58 )

System
======
   CPU type: AMD Athlon(tm) 64 X2 Dual Core Processor 5600+ 2900 Mhz
   Hardware memory: 3072 megs

   Free System resources: 0 %
        GDI    resources: 0 %
        User   resources: 0 %

   Windows total applications running: 12
      1 , C:\Programmi\OpenOffice.org 3\program\soffice.bin
      2 , C:\WINDOWS\Explorer.EXE
      3 , C:\WINDOWS\RTHDCPL.EXE
      4 , C:\work\PRG\Family\main.Exe
      5 , C:\work\xMate\xMate.Exe
      6 ATI video bios poller client, C:\WINDOWS\system32\Ati2evxx.exe
      7 CDirectoryChangeWatcherHelperWindow, C:\Programmi\File comuni\Ahead\Lib\NMBgMonitor.exe
      8 CiceroUIWndFrame, C:\WINDOWS\system32\ctfmon.exe
      9 Code display: [code]code
, C:\Programmi\Mozilla Firefox\firefox.exe
     10 DirectDBListenWndProc, C:\Programmi\File comuni\Ahead\Lib\NMIndexStoreSvr.exe
     11 HPSISVC, C:\WINDOWS\system32\HPSIsvc.exe
     12 New PC Studio, C:\Programmi\Samsung\Samsung New PC Studio\NPSAgent.exe

Variables in use
================
   Procedure     Type   Value
   ==========================
   TCLIPGET:UNTRANSFORM
     Local   1:    N    1
     Local   2:    O    Class: TCLIPGET
     Local   3:    U    
     Local   4:    L    .T.
     Local   5:    U    
     Local   6:    N    1
     Local   7:    N    0
     Local   8:    C    ""
     Local   9:    C    "N"
     Local  10:    U    
     Local  11:    U    
     Local  12:    N    1
     Local  13:    N    1
     Local  14:    U    
     Local  15:    U    
   TCLIPGET:ASSIGN
     Local   1:    O    Class: TCLIPGET
     Local   2:    U    
     Local   3:    O    Class: TCLIPGET
   TGET:LVALID
     Local   1:    O    Class: TGET
     Local   2:    L    .T.
   TGET:FWLOSTFOCUS
     Param   1:    N    328624
     Local   1:    O    Class: TGET
     Local   2:    U    
     Local   3:    U    
   TCONTROL:HANDLEEVENT
     Param   1:    N    2057
     Param   2:    N    328624
     Param   3:    N    0
     Local   1:    O    Class: TGET
     Local   2:    U    
   TGET:HANDLEEVENT
     Param   1:    N    2057
     Param   2:    N    328624
     Param   3:    N    0
     Local   1:    O    Class: TGET
     Local   2:    U    
     Local   3:    U    
     Local   4:    U    
   _FWH
     Param   1:    N    0
     Param   2:    N    2057
     Param   3:    N    328624
     Param   4:    N    0
     Param   5:    N    70
     Local   1:    O    Class: TGET
   DIALOGBOXINDIRECT
     Param   1:    N    4194304
     Param   2:    C    "€ È€     ÿuÿâ ¯     F i v e W i n   f o r   H a r b o u r       P    4 u .S T A T I C         E r r o r   d e s c r i p t i o n :   E r r o r   B A S E / 1 0 7 2     A r g u m e n t   e r r o r :   < >
 
          P     H /S T A T I C   & S t a c k   L i s t        ¡P     ! Ü  0L I S T B O X         P    a ¢ 1B U T T O N   & Q u i t         P    ¯ / 2B U T T O N   S e e   e r r o r . l o g   f i l e     "
     Param   3:    N    328536
     Param   4:    O    Class: TDIALOG
   TDIALOG:ACTIVATE
     Param   1:    U    
     Param   2:    U    
     Param   3:    B    {|| ... }
     Param   4:    L    .T.
     Param   5:    U    
     Param   6:    L    .T.
     Param   7:    U    
     Param   8:    U    
     Param   9:    U    
     Param  10:    L    .F.
     Param  11:    L    .F.
     Local   1:    O    Class: TDIALOG
     Local   2:    N    328536
     Local   3:    U    
     Local   4:    U    
     Local   5:    U    
     Local   6:    O    Class: TDIALOG
   ERRORDIALOG
     Param   1:    O    Class: ERROR
     Local   1:    O    Class: TDIALOG
     Local   2:    O    Class: TLISTBOX
     Local   3:    U    
     Local   4:    U    
     Local   5:    C    "   Called from: .\source\classes\TGET.PRG => TGET:LOSTFOCUS( 1200 )"
     Local   6:    N    9
     Local   7:    C    "   Error description: Error BASE/1072  Argument error: <>
"
     Local   8:    A    Len:   18
     Local   9:    O    Class: TSAY
     Local  10:    N    1929711643
     Local  11:    N    1
     Local  12:    C    "Application
===========
   Path and name: C:\work\PRG\Family\main.Exe (32 bits)
   Size: 3,825,664 bytes
   Compiler version: xHarbour build 1.2.1 Intl. (SimpLex) (Rev. 6715)
   FiveWin  Version: FWHX 12.03
   Windows version: 5.1, Build 2600 Service Pack 2

   Time from start: 0 hours 1 mins 44 secs
   Error occurred at: 06-11-2012, 09:41:00
   Error description: Error BASE/1072  Argument error: <>
   Args:
     [   1] = N   1
     [   2] = C   Annuale[/code]






the error is on line 900
on this line I set a get object to disable

ACTIVATE DIALOG oDlg ;
ON INIT (DlgCenter(oDlg,oApp():oWndMain),;
aGet[9]:disable(),;
aGet[11]:disable() )



these aGet are two comboboxes :

@ 102, 56 COMBOBOX aGet[9] VAR nPeivarep ITEMS aIvaRep1 OF ....
@ 114, 56 COMBOBOX aGet[11] VAR nPerecing ITEMS aIvaRep1 OF....


But the error come when the user change another combobox in this dialog

@ 187, 56 COMBOBOX aGet[16] VAR nPEPERIODIC ITEMS aPeriodi OF oDlg SIZE 40, 95 PIXEL STYLE CBS_DROPDOWN

and click on one of the 12 checkboxex they have another array lcheckMesi[12]

sample :

@ 200, 56 CHECKBOX oChkMesi VAR lChkMesi[1] OF oDlg SIZE 35, 8 PIXEL PROMPT "Gennaio"



the error come when I select he combobox aGet[16]

the variable is numeric ( n,1)

Error description: Error BASE/1072 Argument error: <>
Args:
[ 1] = N 1
[ 2] = C Annuale


ANY SOLUTION ?

Re: Error with TclipGet

Posted: Tue Nov 06, 2012 11:05 am
by Silvio.Falconi
this is a minimal test to see the error Tclipget

Code: Select all

#include "FiveWin.ch"
#include "xBrowse.ch"


#include "constant.ch"
#include "Report.ch"


Function Test()
   local oDlg, oFld, oBmp
   Local nBottom   := 36.9
   Local nRight    := 46
   Local nWidth :=  Max( nRight * DLG_CHARPIX_W, 180 )
   Local nHeight := nBottom * DLG_CHARPIX_H

      Local aPeriodi := {"Annuale","Semestrale","Trimestrale","Bimestrale","Mensile" }
      Local  oChkMesi, lChkMesi[12], aMese[12]
     local aGet[20]

       Local aIvaRep1:=  {}
       Local aIvaRep2:=  {}

              cPemeses:="000000000000"
              nPeivarep:=0
              nPerecing:=0
              nPEPERIODIC :=1

              aMese[1]:= Left(cPemeses, 1)
              aMese[2]:= SubStr(cPemeses, 2, 1)
              aMese[3]:= SubStr(cPemeses, 3, 1)
              aMese[4]:= SubStr(cPemeses, 4, 1)
              aMese[5]:= SubStr(cPemeses, 5, 1)
              aMese[6]:= SubStr(cPemeses, 6, 1)
              aMese[7]:= SubStr(cPemeses, 7, 1)
              aMese[8]:= SubStr(cPemeses, 8, 1)
              aMese[9]:= SubStr(cPemeses, 9, 1)
              aMese[10] := SubStr(cPemeses, 10, 1)
              aMese[11] := SubStr(cPemeses, 11, 1)
              aMese[12] := Right(cPemeses, 1)


            FOR n=1 TO 12
                    IF  aMese[n]="1"
                        lChkMesi[n]  := .T.
                     else
                        lChkMesi[n]  := .F.
                     endif
                next





 DEFINE DIALOG oDlg        ;
   TITLE "TEST TCLIPGET"    ;
   SIZE nWidth, nHeight  TRANSPARENT PIXEL        




@ 102, 56 COMBOBOX aGet[9] VAR nPeivarep ITEMS aIvaRep1  OF oDlg SIZE 40, 45 PIXEL      STYLE CBS_DROPDOWN

@ 114, 56 COMBOBOX aGet[11] VAR nPerecing ITEMS aIvaRep1  OF oDlg SIZE 40, 95 PIXEL   STYLE CBS_DROPDOWN




 @ 187, 56 COMBOBOX aGet[16] VAR nPEPERIODIC ITEMS aPeriodi  OF oDlg SIZE 40, 95 PIXEL   STYLE CBS_DROPDOWN



 @ 200, 10 SAY "Mesi:" OF oDlg SIZE 35, 8 PIXEL

     @ 200, 56     CHECKBOX oChkMesi VAR lChkMesi[1] OF oDlg SIZE 35, 8  PIXEL  PROMPT "Gennaio"



     ACTIVATE DIALOG   oDlg   CENTER ;
     ON INIT (aGet[9]:disable(),;
              aGet[11]:disable() )
 


IF YOu select the third combobox and click on checkbox it run error Tclipget


ANy SOlution ?

Re: Error with TclipGet

Posted: Tue Nov 06, 2012 11:31 am
by BeoBeo
U speak with yourself ?

Re: Error with TclipGet

Posted: Tue Nov 06, 2012 12:26 pm
by Enrico Maria Giordano

Code: Select all

LOCAL nPEPERIODIC :="1"
EMG

Re: Error with TclipGet

Posted: Tue Nov 06, 2012 5:29 pm
by Silvio.Falconi
BeoBeo wrote:U speak with yourself ?

:) no at Work have a pc with Eoeo account but I not remember the password
At Home I write with the another account...

Re: Error with TclipGet

Posted: Tue Nov 06, 2012 5:32 pm
by Silvio.Falconi
Enrico Maria Giordano wrote:

Code: Select all

LOCAL nPEPERIODIC :="1"
EMG

Emg I have nPEPERIODIC := PE->PEPERIODIC

{ "PEPERIODIC", "N", 1, 0 },;

and it is numeric field why I must converte to string ?

if i set nPEPERIODIC := str(PE->PEPERIODIC)

then on modify on the combobox It show an number instead of the selection string as you can see here :

Image

Re: Error with TclipGet

Posted: Tue Nov 06, 2012 6:06 pm
by Silvio.Falconi
Perhaps I found the error
I must erase STYLE CBS_DROPDOWN