try this
c#
ClientScript.RegisterStartupScript(GetType(), "JavaScript", "JavaScript:function1([1,2,3,4,5],['one','two','three']); ", true);
Javascript:
function function1(intArray,stringArray) {
console.log(intArray);
console.log(stringArray);
}
for dynamic array[string]:
string[] array = new string[] {"one","two","three","four","five" };
string arrayString = "[";
foreach (string item in array)
arrayString += string.Format("'{0}',", item);
arrayString.Trim().Trim(',');
arrayString = arrayString + "]";
ClientScript.RegisterStartupScript(GetType(), "JavaScript", "JavaScript:function1( " + arrayString + "); ", true);
For Double:
double[] array = new double[] { 1.1,2.2,3.3,4.4,5.5 };
string arrayString = "[";
for (int i = 0; i < array.Length; i++)
arrayString += string.Format("{0},", array[i]);
arrayString.Trim().Trim(',');
arrayString = arrayString + "]";
ClientScript.RegisterStartupScript(GetType(), "JavaScript", "JavaScript:function1( " + arrayString + "); ", true);
another way: javascript - passing c# array to java script[
^]
Passing arrayList to javascript function[
^]