Output text after space in cells

Hi there,

How do I use split expression to split between date and value into another cells. I can’t figure out the expression to use “for each row in datatable”. The value on the right side is dynamic value. Can be decimal, 2 digit or can be 1 million digit. But the date is always static on the left while values is on the right side. How do I split them into column B (date) and C (value) just like picture below:

image
test4.xlsx (9.9 KB)

Really appreciate the helps :smiley:

1 Like

Hey @DTECH

  1. Read range activity reads the excel data into a table

  2. Use For-Each Row to iterate rows

2a. Assign currentRow(1) = currentRow(0).ToString.Split(" "c)(0)

2b. Assign currentRow(2) = currentRow(0).ToString.Split(" "c)(1)

  1. Outside For-each just use a write range and write the same table back to Excel into the same sheet

Hope this helps.

Thanks
#nK

image
Sorry, Im having error with this

1 Like

@DTECH At what point please ?

Hi @DTECH,

Can you share an example input and output excel?

Regards,
MY

stopped on second assign (2.b)

test4.xlsx (9.9 KB)

Here example

1 Like

Could you please show what did you do in that assign ?

image
image

Same as your step, read range → for each assign → write range

But it stop at 2nd assign

@DTECH can you try currentRow(0).ToString.Split(" “)[0] & currentRow(0).ToString.Split(” ")[1]

Hi @DTECH,

I am sharing a simple example that you can use. I hope it helps.

simpleExample.xaml (9.9 KB)

Regards,
MY

Thanks, appreciated :smiley:

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.