substring of a variable

Hi,

In a rule I want to take apart DeviceCustomSring1 which has the value "#999.999" into two fields.  So I need to:

(1) Find x = index_of("#999.999", ".")

(2) Find y = SubString( "#999.999", 1, x)

So can I save X above as an intermediate value in this rule and then use x as input to y?----regards, WER

Tags:

Parents
  • I agree with chris. There is also another way to get the second substring.

    1. Use a lengthof variable to grab the total number of characters in the string

    2. use a subtract variable to subtract the integer from your first indexof from the integer from lengthof variable

    3. substring the string starting your cut at 'subtractvariable' and stopping at 'lengthofvariable'.

    this should work best for grabbing the second substring

Reply
  • I agree with chris. There is also another way to get the second substring.

    1. Use a lengthof variable to grab the total number of characters in the string

    2. use a subtract variable to subtract the integer from your first indexof from the integer from lengthof variable

    3. substring the string starting your cut at 'subtractvariable' and stopping at 'lengthofvariable'.

    this should work best for grabbing the second substring

Children
No Data