Hello Mick and welcome to the board

Take a look at this post which shows an example of what I think your looking for.

System Time

Here is another link on similar issue different discussion.
Generalized base conversion

and one more
Removing certain characters from a string

One of these should help point you in the right direction. Hope this helps and if you still need further help please post again and ask.