Hi Mike,
If you know where the numbers in the string will be you can use the Mid(yourstring,14,3) function to get the characters then use CDbl(yourstringhere) function to convert it into a Double (numeric value).....(take a look in iLogic under the 'Strings' section, theres some useful snippets in there)
Example :
test = Mid(iProperties.Value("Custom", "CUSTOMPROP"),14,3)
your_numerical_value = CDbl(test)
That will extract the 14th, 15th and 16th character in from the left (this is defined by the "14,3" in the mid function) and convert it to a Double.
If you can't guarantee the position of the numbers in the string you can use some code like this :
Dim test As String = iProperties.Value("Custom", "CUSTOMPROP")
Dim test2 As String = "" 'create an empty string to pass the digits into
Dim CharArray() As Char = test.ToCharArray() 'split the string into characters and pass into an array
For Each chara As Char In CharArray
If Char.IsDigit(chara) Then
test2 = test2 & chara 'look at each character in the array, if it is a digit then concatenate it into the test2 string
End If
Next
yourparam = CDbl(test2)
This chunk of code will take your string, break it into characters and pass each character into an array, check each character in the array to see if it is a digit and if it is concatenate it in a new string.
Because we know the new string only contains digits, we can use the CDbl(yourstringhere) function to convert it into a Double.
Maybe the second option is a bit of overkill but it may be of use in the future!
Tom