* Use one time in your initialization code: DECLARE INTEGER bgn_Initialize IN bignums.dll INTEGER nRows, INTEGER nCols DECLARE INTEGER bgn_SetPrecision IN bignums.dll INTEGER nDigits DECLARE INTEGER bgn_SetValue IN bignums.dll STRING cCell, STRING cValue DECLARE INTEGER bgn_GetValue IN bignums.dll STRING cCell, INTEGER nWidth, INTEGER nDecimals, STRING@ output DECLARE INTEGER bgn_SetFormula IN bignums.dll STRING cCell, STRING cFormula bgn_Initialize(100, 50) bgn_SetPrecision(32) * Use as-needed to set your data: bgn_SetValue("A1", "104020109010404010101") * Use as-needed to retrieve your data: lcResult = SPACE(32) bgn_GetValue("A1", 32, 0, @lcResult) * Answer is in ALLTRIM(lcResult) * You can do any math you want to with it: bgn_SetValue("B1", "5") bgn_SetFormula("B2", "A1+B1") * Each time you read the cell with a formula, it re-computes and you'll get the new value. * So you can populate new values into B1, and it will re-compute each time. lcResult = SPACE(32) bgn_GetValue("B2", 32, 0, @lcResult) * Answer is in ALLTRIM(lcResult)Also, you can also use CHRTRAN(string, ".", SPACE(0)) to get rid of the periods in a number and just have the digits.
lcSource = "1.2.11.3" lcConverted = CHRTRAN(lcSource, ".", SPACE(0)) ? lcConverted>Hi,
>*!* PROCEDURE conversion >LPARAMETERS lcNumberIn > >Local ; > lcNewpar As String, ; > lcNumberIn As String, ; > lnI As Number, ; > lnParenteel As Number > > >*!* ? lcNumberIn >m.lcNewpar = '' > >For m.lnI = 1 To Len(Alltrim(m.lcNumberIn )) > Do Case > Case !Isdigit(Substr(m.lcNumberIn ,m.lnI,1)) > m.lcNewpar = m.lcNewpar +Substr(m.lcNumberIn ,m.lnI,1) > Case Isdigit(Substr(m.lcNumberIn ,m.lnI,1)) > m.lcNewpar = m.lcNewpar + Iif(Isdigit(Substr(m.lcNumberIn ,m.lnI,1)), Padl(Substr(m.lcNumberIn ,m.lnI,1),2,'0'), Substr(lcParenteel ,m.lnI,1)) > > Endcase >Endfor >m.lcNewpar = Strtran(m.lcNewpar ,'010','1') >m.lcNewpar = Strtran(m.lcNewpar ,'.','') >m.lcNewpar = ALLTRIM(Substr(m.lcNewpar ,2)) >RETURN val(m.lcNewpar) >>