To get a single, clean list, like the above, from data like this:
{{}, {}, {}, {}, {{10680042}}, {{10680042}}, {{12088057}}, {{12323057}}, {{12324057}}, {{12325057}}, {}, {{13085070}}, {}, {{13850070}}, {{14330070}}, {{14331070}}, {{14801070}}, {{15175070}}, {{15948070}},
You can just use 2 Search & Replace Actions on the Source Data:
- Search for any of these characters, and replace with NOTHING:
(the bracket[]
tell the RegEx engine to use ANY of the characters between them)
Search using RegEx:[{} \n]
Replace:<nothing>
(leave the replace field blank)
- Search for commas, and replace with linefeed:
Search:,
Replace:\n
You should already know how to do this. We answered that question for you here:
Removing duplicate strings from Array stored as KM Variable[quote="demirtas1, post:1, topic:7059"]
My aim after removing the duplicate, save each result in turn to a variable then execute a particular set of macro actions.
[/quote]
I hope you don't mind me saying so, but I think that is a bad idea.
We could create the KM Variables, but having tens of Variables named Var01, Var02, ... Var50 would be a nightmare to use later.
Instead, you need some way to identify what each number extracted is used for. Account numbers?
One approach is to build a single KM Variable which contains all of the numbers, one per line, and use them in a KM For_Each action (KM Wiki) on a sequential basis, OR extract a particular number based on line# or part of the number, using a Search_Variable action (KM Wiki) with a RegEx.
###Need More Info
Before we spend any more time trying to come up with specific solutions, please post in detail the workflow you want to automate.