plus keep in mind that doubles only go to 16 decimal places
although perhaps the numeric string is actually being cast to a long, but then I wonder why it resorts to e-notation which I though was a floating-point thing
If you only ever increment by 1, then you can increment strno without conversion to numeric type and back. I use this when doing variable-length binary or octal or hexadecimal or alphabetical sequences.
That doesn't quite match your code sample, where eg the increment is increasing, but I think anyway that your immediate problem is more like: how to get rid of the E-notation eg E+11
Dim strno As String = "185678941238"
For intno = 0 To 10
If intno > 0 Then
strno = NumberFormat2((strno + intno), 1, 0, 0, False)
End If
Log(intno & ". " & strno)
Next
And if that skips a bit because it's maybe still going through the E-notation wringer somewhere, try:
B4X:
Dim strno As String = "185678941238"
For intno = 0 To 10
If intno > 0 Then
dim L as long = strno
L = L + intno
strno = L 'or if you still get E-notation, try: strno = NumberFormat2(L, 1, 0, 0, False)
End If
Log(intno & ". " & strno)
Next