Function to split either a string array or string into a string array
if (delimiter == "&lt;newline&gt;") delimiter = "\n";


Why do you need this? Why not use normal strings?

if (thevar.GetType() == typeof(string)) {


What's wrong with normal method overloading?

if (thevar.GetType() == typeof(string)) {...}
if (thevar.GetType() == typeof(string[])) {...}
return null;


If arguments is not valid throw an ArgumentException. Don't say "I'll just return null, and see where it will go wrong."

temp.Split(new string[] {delimiter}, System.StringSplitOptions.None);


This bit repeats, and should be extracted into a method.

for (int i = 0; i &lt; tempr.Length; i++) {
    for (int j = 0; j &lt; tempr[i].Length; j++) {


Use Linq to simplify loop operations.

Here is the cleaned up version:

    public IEnumerable&lt;string&gt; Split(string str, string delimiter)
    {
        return str.Split(new[]{delimiter}, StringSplitOptions.None);
    }

    public IEnumerable&lt;string&gt; Split(IEnumerable&lt;string&gt; arr, string delimiter) {
        return arr.SelectMany(s =&gt; Split(s, delimiter));
    }