📄 verutil.prg
字号:
LPARAMETER tcDirectory
IF DIRECTORY( tcDirectory )
LOCAL laVCX[1], ;
lcCurDir, ;
lcCurDir, ;
lnNumVCX, ;
lnRow, ;
lcVCXName, ;
lnPropLength, ;
lnNumberOfVersionProperties, ;
lnCount, ;
lnVersionPropertyNameStart, ;
lcVersionValue, ;
lnVersionValueBegin, ;
lnVersionValueEnd, ;
lnVersionValueLength, ;
lcVersion, ;
lcNewProperties
lcCurDir = SYS(5) + CURDIR()
CD (tcDirectory)
lnNumVCX = ADIR( laVCX, "*.VCX" )
FOR lnRow = 1 TO lnNumVCX
lcVCXName = laVCX[lnRow,1]
USE ( tcDirectory + lcVCXName )
SCAN
SCATTER MEMO MEMVAR
lnPropLength = LEN(ALLTRIM(m.properties))
lnNumberOfVersionProperties = OCCURS( UPPER("cVersion"), UPPER(m.properties) )
FOR lnCount = 1 to lnNumberOfVersionProperties
lnVersionPropertyNameStart = AT( UPPER("cVersion"), ;
UPPER(m.properties), ;
lnCount )
IF lnVersionPropertyNameStart > 0
*----------------------------------------------------------------------
*-- Obtain a string that begins with the property name "cVersion"
*----------------------------------------------------------------------
lcVersionValue = SUBSTR( m.properties, lnVersionPropertyNameStart, 87)
*---------------------------------------------------
*-- Extract the value of the cSecurityLabel property
*---------------------------------------------------
lnVersionValueBegin = AT( "=", lcVersionValue ) + 1
lnVersionValueEnd = AT( CHR(13), lcVersionValue )
lnVersionValueLength = lnVersionValueEnd - lnVersionValueBegin
lcVersion = SUBSTR( lcVersionValue, ;
lnVersionValueBegin, ;
lnVersionValueLength )
*-----------------------------------------------------------------------
*-- If no Security Label has been assigned to this control, skip over it
*-- and move to the next one.
*-----------------------------------------------------------------------
IF EMPTY( lcVersion )
LOOP
ENDIF
lcNewProperties = STRTRAN(m.properties,lcVersion,"06.00.0001")
REPLACE properties WITH lcNewProperties
ELSE
LOOP
ENDIF
ENDFOR && -lnCount = 1 to lnNumberOfSecurityLabels
ENDSCAN
USE
COMPILE CLASSLIB ( tcDirectory + lcVCXName )
ENDFOR
ENDIF
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -