0

I am getting this error at run time can any body help me out why i am getting this Error?

Thanks

ShowHelpTopic('/Help/Help2.htm');;void(0)

This is the Error I am getting in the Dynamic mode page.

This is my code in the page.

stm_aix("p3i0", "p1i0", [0, "Searching for items in Benefit Code list", "", "", -1, -1, 0, "javascript:ShowHelpTopic('/Help/Help1.htm')", "_self", "", "Help Topics", "060508icon4.gif", "060508icon5.gif"], 526, 0);stm_aix("p3i0", "p1i0", [0, "Creating new Benefit Codes", "", "", -1, -1, 0, "javascript:ShowHelpTopic('/Help/Help2.htm')", "_self", "", "Help Topics", "060508icon4.gif", "060508icon5.gif"], 526, 0);

This ShowHelpTopic function in my js file.

function ShowHelpTopic(url){
    window.open(url, "HelpTopics", "height=600,width=900,resizable=1,menubar=0,toolbar=0,location=0,directories=0,scrollbars=1,status=0");
}

Why am I getting a run time error in my asp.net mvc application?

1
  • 1
    I'd guess your item variable isn't an object, how do you initialise it? Commented Sep 9, 2011 at 19:18

1 Answer 1

1

Either urls doesn't exist when you are prepending it to itself or item is null. Because this sample is fine:

var urls = "", 
    item = {helpLinkDescription: 'a', helpLink1: 'google'};
urls += 'stm_aix("p3i0", "p1i0", [0, "' + item.helpLinkDescription + "\", \"\", \"\", -1, -1, 0, \"" + "javascript:ShowHelpTopic('" + item.helpLink1 + "');" + "\", \"_self\", \"\", \"Help Topics\", \"060508icon4.gif\", \"060508icon5.gif\"], 526, 0);";
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.