Skip to Content
avatar image
Former Member

Error: String length is less than 0 or not an integer

Hello everyone,

I am kind of newbie here but soon it will change I hope so 😊

So... I have a field which is number but combine with string - (lets say "500 km" for example).

I need to remove the 'km' part of it and to stay only number - 500.

This happen with:

tonumber (mid ({Command.string_field},1,(INSTR({Command.string_field}, "km")-1)))

But when i try to export it in pdf it gives me this error message - "string length is less than 0 or not an integer".

Any ideas how can manage with this??

Thank you in advance 😊

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • Best Answer
    Oct 21, 2015 at 12:05 PM

    Hi Parvoleta,

    Try changing the code to:

    Val({Command.string_field})

    -Abhilash

    Add comment
    10|10000 characters needed characters exceeded