-------------------------------------------------------------------------------------------
# Dependency: Satimage.osax
on fndUsing(fndStr, returnStr, srcData, caseSensitive, regExFlag, wholeWord, allOccurrences, stringResult)
try
set findResult to find text fndStr in srcData case sensitive caseSensitive regexp regExFlag ¬
whole word wholeWord using returnStr all occurrences allOccurrences string result stringResult
on error
return false
end try
end fndUsing
-------------------------------------------------------------------------------------------
set strA to "Smile 3.6.1 (build 710) full edition"
set strB to "Smile 3.7.0 (build 768) full edition"
if not (strA = strB) then
set _ver to fndUsing("Smile ([\\d.]+)", "\\1", strB, false
, true
, false
, false
, true
) of me set _build to fndUsing("build (\\d+)", "\\1", strB, false
, true
, false
, false
, true
) of me end if