Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » RCP Testing Tool » problems converting long
problems converting long [message #1749520] Wed, 07 December 2016 17:17 Go to next message
Violaine Batthish is currently offline Violaine BatthishFriend
Messages: 3
Registered: July 2009
Junior Member
I need to convert a hex string to a long
when I try
long "0X26DC75"
it works. But when I try
long [concat "0X" "26DC75"]
or
long "26DC75"
I get an error:
Cannot convert string to long

Any advice?
Re: problems converting long [message #1750118 is a reply to message #1749520] Fri, 16 December 2016 09:31 Go to previous message
Artem Kovalev is currently offline Artem KovalevFriend
Messages: 25
Registered: April 2016
Junior Member
Hi Violaine,

The operation long [concat "0X" "26DC75"] works fine and problem is not reproduced.

long "26DC75" - failed because 26DC75 it is not hex number. (the hex number start from 0x).
We can not parse hex value without 0x prefix, because it maybe ambiguously. For example the number "100000" can be either hex or decimal number. You can see same behavior on a java language (Long.parseLong("26DC75") - will throw exception)

Previous Topic:gogo: InterruptedException: sleep interrupted on RCPTT 2.1 official
Next Topic:Custom ECL Commands
Goto Forum:
  


Current Time: Fri Sep 21 01:03:15 GMT 2018

Powered by FUDForum. Page generated in 0.01776 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top