%If (False) Then%> <% End If%> function GetStudentLetterTemplate(schoolyear, schoolnum, milestone, studentlink, language, semester) { alert('schoolyear: ' + schoolyear + 'schoolnum: ' + schoolnum + 'milestone: ' + milestone + 'studentlink: ' + studentlink + 'language: ' + language + 'semester: ' + semester); if (milestone == '999') { alert('You have selected student(s) having more than one CAIP entry for the current school year'); return; } }", "answerCount": 4, "datePublished": "2016-09-17T18:38+00:00", "author": { "@type": "Person", "name": "dc ", "url": "https://www.csharp.com/members/dc" } , "suggestedAnswer": [ { "@type": "Answer", "text": "Hi, javascript debugging can be done from browsers. Just follow below links - https://scotch.io/tutorials/debugging-javascript-with-chrome-devtools-breakpoints http://stackoverflow.com/questions/988363/how-can-i-debug-my-javascript-code", "upvoteCount": 0, "url": "https://www.csharp.com/forums/javascript-alert-message", "datePublished": "2016-09-18T22:12+00:00", "author": { "@type": "Person", "name": "Midhun Tp", "url": "https://www.csharp.com/members/midhun-tp" } }, { "@type": "Answer", "text": " Can you tell me and/or point me to a link (url) that will tell me how to do the following: 'debug on javascript code\" ", "upvoteCount": 0, "url": "https://www.csharp.com/forums/javascript-alert-message", "datePublished": "2016-09-18T14:25+00:00", "author": { "@type": "Person", "name": "dc ", "url": "https://www.csharp.com/members/dc" } }, { "@type": "Answer", "text": " Hi, Can you please specify what is the error you getting with above code? First of all, you should place the function GetStudentLetterTemplate inside a script tag. Next you have to call that function wherever you requires. function GetStudentLetterTemplate(schoolyear, schoolnum, milestone, studentlink, language, semester) { alert('schoolyear: ' + schoolyear + 'schoolnum: ' + schoolnum + 'milestone: ' + milestone + 'studentlink: ' + studentlink + 'language: ' + language + 'semester: ' + semester); if (milestone == '999') { alert('You have selected student(s) having more than one CAIP entry for the current school year'); return; } } Now you can call above function like below - GetStudentLetterTemplate(pass parameters value here) ", "upvoteCount": 0, "url": "https://www.csharp.com/forums/javascript-alert-message", "datePublished": "2016-09-17T23:52+00:00", "author": { "@type": "Person", "name": "Midhun Tp", "url": "https://www.csharp.com/members/midhun-tp" } }, { "@type": "Answer", "text": " Hi, you are doing good ,use debug on javascript code and found exact error location.. ", "upvoteCount": 0, "url": "https://www.csharp.com/forums/javascript-alert-message", "datePublished": "2016-09-17T23:51+00:00", "author": { "@type": "Person", "name": "Bikesh Srivastava", "url": "https://www.csharp.com/members/bikesh-srivastava2" } } ] } }