Buenas tardes
Al suprimir las Tabs de un FolderEx y llegar al ultimo elemento me da el siguiente error:
Aclarar que antes de suprimir añado un item (AddItem)
He mirado la clase que tengo y la linea en la que aparece el error es:
La funcion en la que se produce el error
Y los valores:
Len( oFldUtiles:aDialogs ) -> 2 (Ya que he añadido antes de borrar)
nOpt -> 1 (Posicion actual)
No encuentro el problema
He intentado, asignando Brush a todos los Dialogs que voy creando por si acaso sin ningun resultado
He buscado por el foro y no encuentro ninguna referencia sobre el tema.
Gracias
Al suprimir las Tabs de un FolderEx y llegar al ultimo elemento me da el siguiente error:
Aclarar que antes de suprimir añado un item (AddItem)
He mirado la clase que tengo y la linea en la que aparece el error es:
METHOD PaintTB() CLASS TFolderEx
LOCAL aRect := GetClientRect( ::hWnd )
LOCAL n, j
LOCAL nLen := Len( ::aPrompts )
LOCAL hBmpPaint
LOCAL nLastRow
Linea 1358 LOCAL hBrush, hDlgBrush := ::aDialogs[ ::nOption ]:oBrush:hBrush//CreateSolidBrush( CLR_WHITE )// Compiler version: Harbour 3.2.0dev (Rev. 17516)
FiveWin Version: FWH 12.02
Windows version: 6.2, Build 9200
Time from start: 0 hours 0 mins 35 secs
Error occurred at: 29/05/2013, 19:23:00
Error description: Error BASE/1132 Bound error: array access
Args:
[ 1] = A { ... }
[ 2] = N 2
Stack Calls
===========
Called from: .\source\classes\TFOLDEX.PRG => TFOLDEREX:PAINTTB( 1358 )
Called from: .\source\classes\TFOLDEX.PRG => TFOLDEREX:PAINT( 1130 )
Called from: .\source\classes\TFOLDEX.PRG => (b)TFOLDEREX( 117 )
Called from: .\source\classes\TFOLDEX.PRG => TFOLDEREX:DISPLAY( 0 )
Called from: .\source\classes\CONTROL.PRG => TCONTROL:HANDLEEVENT( 1666 )
Called from: .\source\classes\TFOLDEX.PRG => TFOLDEREX:HANDLEEVENT( 925 )
Called from: .\source\classes\WINDOW.PRG => _FWH( 3159 )
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\TFOLDEX.PRG => TFOLDEREX:CHANGEORDER( 651 )
Called from: .\source\classes\TFOLDEX.PRG => TFOLDEREX:RESIZE( 1550 )
Called from: .\source\classes\TFOLDEX.PRG => TFOLDEREX:DEFAULT( 791 )
Called from: .\source\classes\TFOLDEX.PRG => TFOLDEREX:DELITEM( 725 )
Called from: vmh.prg => CIERRA( 1946 )
Called from: vmh.prg => (b)BARFLDS( 1917 )
Called from: .\source\classes\BTNBMP.PRG => TBTNBMP:CLICK( 465 )
Called from: .\source\classes\BTNBMP.PRG => TBTNBMP:LBUTTONUP( 656 )
Called from: .\source\classes\CONTROL.PRG => TCONTROL:HANDLEEVENT( 1690 )
Called from: .\source\classes\BTNBMP.PRG => TBTNBMP:HANDLEEVENT( 1407 )
Called from: .\source\classes\WINDOW.PRG => _FWH( 3159 )
Called from: => WINRUN( 0 )
Called from: .\source\classes\WINDOW.PRG => TMDIFRAME:ACTIVATE( 980 )
Called from: vmh.prg => MAIN( 774 )La funcion en la que se produce el error
Function Cierra()
Local nOpt := oFldUtiles:nOption //aDialogs[ 7 ]
Local nLenD := Len( oFldUtiles:aDialogs )
Local nPosD := 0
if nLenD = 1
oFldUtiles:AddItem( "NONE", , , )
oFldUtiles:SetOption( 2 )
nPosD := 1
else
if nLenD = 2
nPosD := 1
else
nPosD := nOpt - 1
endif
endif
//if nLenD > 1
? Len( oFldUtiles:aDialogs ), nOpt
oFldUtiles:DelItem( nOpt ) // Linea 1946
.../...Y los valores:
Len( oFldUtiles:aDialogs ) -> 2 (Ya que he añadido antes de borrar)
nOpt -> 1 (Posicion actual)
No encuentro el problema
He intentado, asignando Brush a todos los Dialogs que voy creando por si acaso sin ningun resultado
He buscado por el foro y no encuentro ninguna referencia sobre el tema.
Gracias
Cristobal Navarro
Hay dos tipos de personas: las que te hacen perder el tiempo y las que te hacen perder la noción del tiempo
El secreto de la felicidad no está en hacer lo que te gusta, sino en que te guste lo que haces
Hay dos tipos de personas: las que te hacen perder el tiempo y las que te hacen perder la noción del tiempo
El secreto de la felicidad no está en hacer lo que te gusta, sino en que te guste lo que haces