- Added more LOG info for certaing TAG parsing
This commit is contained in:
@@ -6623,12 +6623,21 @@ DEFINE CLASS c_conversor_base AS Custom
|
|||||||
EXTERNAL ARRAY taPropsAndValues
|
EXTERNAL ARRAY taPropsAndValues
|
||||||
|
|
||||||
LOCAL lcMetadatos, I, lcVirtualMeta, lnPos1, lnPos2, lnLastPos, lnCantComillas ;
|
LOCAL lcMetadatos, I, lcVirtualMeta, lnPos1, lnPos2, lnLastPos, lnCantComillas ;
|
||||||
, loLang as CL_LANG OF 'FOXBIN2PRG.PRG'
|
, loLang as CL_LANG OF 'FOXBIN2PRG.PRG' ;
|
||||||
|
, loEx as Exception
|
||||||
|
|
||||||
|
TRY
|
||||||
loLang = _SCREEN.o_FoxBin2Prg_Lang
|
loLang = _SCREEN.o_FoxBin2Prg_Lang
|
||||||
STORE '' TO lcVirtualMeta
|
STORE '' TO lcVirtualMeta
|
||||||
STORE 0 TO lnPos1, lnPos2, lnLastPos, tnPropsAndValues_Count, I
|
STORE 0 TO lnPos1, lnPos2, lnLastPos, tnPropsAndValues_Count, I
|
||||||
|
|
||||||
lcMetadatos = ALLTRIM( STREXTRACT( tcLineWithMetadata, tcLeftTag, tcRightTag, 1, 1) )
|
lcMetadatos = ALLTRIM( STREXTRACT( tcLineWithMetadata, tcLeftTag, tcRightTag, 1, 1) )
|
||||||
|
|
||||||
|
IF EMPTY(lcMetadatos)
|
||||||
|
* Puede que la línea esté separada con un CR erróneo. El usuario debe revisarlo
|
||||||
|
ERROR (TEXTMERGE("Can't identify Metadata TAG '<<tcRightTag>>'. May be the Source line have an extra CR/LF?"))
|
||||||
|
ENDIF
|
||||||
|
|
||||||
lnCantComillas = OCCURS( '"', lcMetadatos )
|
lnCantComillas = OCCURS( '"', lcMetadatos )
|
||||||
|
|
||||||
IF lnCantComillas % 2 <> 0 && Valido que las comillas "" sean pares
|
IF lnCantComillas % 2 <> 0 && Valido que las comillas "" sean pares
|
||||||
@@ -6661,8 +6670,20 @@ DEFINE CLASS c_conversor_base AS Custom
|
|||||||
lnLastPos = lnPos2 + 1
|
lnLastPos = lnPos2 + 1
|
||||||
ENDFOR
|
ENDFOR
|
||||||
|
|
||||||
|
CATCH TO loEx
|
||||||
|
loEx.UserValue = loEx.UserValue + TEXTMERGE('I=<<I>>, lcMetadatos="<<lcMetadatos>>", tcLineWithMetadata="<<tcLineWithMetadata>>"') + CR_LF
|
||||||
|
IF THIS.n_Debug > 0 AND _VFP.STARTMODE = 0
|
||||||
|
SET STEP ON
|
||||||
|
ENDIF
|
||||||
|
|
||||||
|
THROW
|
||||||
|
|
||||||
|
FINALLY
|
||||||
RELEASE tcLineWithMetadata, taPropsAndValues, tnPropsAndValues_Count, tcLeftTag, tcRightTag ;
|
RELEASE tcLineWithMetadata, taPropsAndValues, tnPropsAndValues_Count, tcLeftTag, tcRightTag ;
|
||||||
, lcMetadatos, I, lcVirtualMeta, lnPos1, lnPos2, lnLastPos, lnCantComillas
|
, lcMetadatos, I, lcVirtualMeta, lnPos1, lnPos2, lnLastPos, lnCantComillas
|
||||||
|
|
||||||
|
ENDTRY
|
||||||
|
|
||||||
RETURN
|
RETURN
|
||||||
ENDPROC
|
ENDPROC
|
||||||
|
|
||||||
@@ -8980,6 +9001,7 @@ DEFINE CLASS c_conversor_prg_a_bin AS c_conversor_base
|
|||||||
ENDIF
|
ENDIF
|
||||||
|
|
||||||
CATCH TO loEx
|
CATCH TO loEx
|
||||||
|
loEx.UserValue = loEx.UserValue + TEXTMERGE('Source line=<<I>>') + CR_LF
|
||||||
IF THIS.n_Debug > 0 AND _VFP.STARTMODE = 0
|
IF THIS.n_Debug > 0 AND _VFP.STARTMODE = 0
|
||||||
SET STEP ON
|
SET STEP ON
|
||||||
ENDIF
|
ENDIF
|
||||||
|
|||||||
Reference in New Issue
Block a user