I found a JavaScript function within a .aspx file that I need help with.
<script>
function somefun(value)
{
}
<script>
Within the code-behind class, I am trying to call this function and pass a value.
ScriptManager.RegisterStartupScript(this, typeof(string), "Passing", String.Format("somefun('{0}');", filePath1), false);
However, when I run the code, the function doesn't work properly. The output displayed is
"somefun(the content of the variable)"
What could be causing this issue?