I am new to Regex...

I need to split by "|&|" -- three characters in that exact order. For example, "abc|&|e&f" should return "abc" and "e&f".

I tried

string.split("|&|")

, but it return all single characters.

Check the doc for regular expressions to see if any of those characters are special and need to be escaped.
For example if & is special: "|\\&|"

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.