.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
Gaurav Pal
Post New Web Links

Microsoft JScript runtime error: 'ctl00_ContentPlaceHolder1_ProjectsList1_TextBoxSelectedP...' is

Posted By:      Posted Date: September 08, 2010    Points: 0   Category :ASP.Net
Hello,I have a repeater for html table rows. And inside the onclick of each row I wrote handleClick('somevalue');And here's my javascript handleClick() function:function handleRowClick(rowid) { var selectedvalue=<%=TextBoxSelectedProjectID.ClientID %>; selectedvalue.value = rowid; }  and the control I'm trying to update the value of is a textbox which is defined as follows:<asp:TextBox ID="TextBoxSelectedProjectID" runat="server" Style="display: none;"></asp:TextBox>The problem is: When I click on any row of my html table i get the javascript error telling me is it undefined.(just like the subject of this post)I looked at the generator html code at runtime and here it is: <div id="ctl00_ContentPlaceHolder1_ProjectsList1_mainlayout"> <input name="ctl00$ContentPlaceHolder1$ProjectsList1$TextBoxSelectedProjectID" type="text" id="ctl00_ContentPlaceHolder1_ProjectsList1_TextBoxSelectedProjectID" /> <table cellspacing="1" cellpadding="1" width="100%" onselectstart="return false;" style="background-color: #F8F8F8"> <tr id="fc82fbb858334ba480187cedfb19e88a" class="listRowNormal" onmouseup="handleRowClick('fc82fbb858334ba480187cedfb19e88a');"> <td s

View Complete Post

More Related Resource Links

Microsoft JScript runtime error: 'Parent' is null or not an object


Hi friends,

        I got This Error : Microsoft JScript runtime error: 'Parent' is null or not an object

 In runtime,after  click on the check box, It Show "Microsoft JScript runtime error: 'Parent' is null or not an object"

<script language ="javascript" type ="text/javascript" >
        function SelectAllCheckboxesSpecific(spanChk)
           var IsChecked = spanChk.checked;
           var items=0;
           var Chk = spanChk;
              Parent = document.getElementById('gvUsers');          
              var items = Parent.getElementsByTagName('input');                         
              for(var i=0;i<items.length;i++)
                  if(items[i].id != Chk && items[i].type=="checkbox")
                      if(items[i].checked!= IsChecked)

please verify it. 

Microsoft JScript runtime error: 'net' is undefined.

I get an error at the statement new net.ContentLoader("MyPage.aspx") in Default.aspx page. I am using Visual Studio 2008 and .net framework 2.0.   Please help!

Microsoft JScript runtime error: Sys.WebForms.PageRequestManagerServerErrorException: Object referen



 i have a dropdownlist and Datagrid control on form. i wanted to refresh the grid

on changing  the DropDown OnSelectedIndexChanged, but when i do change

the dropdown value then it give me fallowing error message.

Microsoft JScript runtime error: Sys.WebForms.PageRequestManagerServerErrorException: Object reference not set to an instance of an object.

Can any one help me, how to solve this problem?

Code given below.


                <asp:DropDownList ID="ddColor" runat="server" AutoPostBack="True" OnSelectedIndexChanged="ddColor_SelectedIndexChanged"
                    <asp:ListItem Selected="True">Red</asp:ListItem>

jquery runtime error: Microsoft JScript runtime error: 'nodeName' is null or not an object


Microsoft JScript runtime error: 'nodeName' is null or not an object

in jquery-1.4.2.min.js 

Microsoft JScript runtime error: AjaxControlToolkit requires ASP.NET Ajax 4.0 scripts



  I am getting the following error while using ajax control tookit

Microsoft JScript runtime error: AjaxControlToolkit requires ASP.NET Ajax 4.0 scripts. Ensure the correct version of the scripts are referenced. If you are using an ASP.NET ScriptManager, switch to the ToolkitScriptManager in AjaxControlToolkit.dll.

I am using Visual Studio 2008 with .Net Framwork 3.5 SP 1, i downloaded the Ajax Control Toolkit from codeplex (AjaxControlToolkit.Binary.NET35)

Below given is the markup:

<%@ Page Language="C#" AutoEventWireup="true"  CodeFile="Default.aspx.cs" Inherits="_Default" %>

<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="asp" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title>Untitled Page</title>

Getting "Microsoft JScript runtime" Error


I have added MaskedEditExtender and MaskedEditValidator controls from the Ajax Toolkit for .NET Framework 4.0 to my textboxes to provide enhanced functionality. However, since I've done that I am getting the following error in Visual Studio when I visit the page containing these controls.

Microsoft JScript runtime error: '2.length' is null or not an object

This is the information from the script page that Visual Studio breaks in.

When I right-click on the tab in Visual Studio and choose "Copy Full Path" it gives this.

When I hover over the tab in Visual Studio it gives this (as much as I could see in the tooltip).

This is the piece of code from line 21 of the file above, where Visual Studio breaks.

can't type a single key into login box Microsoft JScript runtime error:


I had to exclude several pages from my website to get it to run in vs 2008. When I finally got the home page to come up, I tried to type a character into the login box, and at the first character the probelm blows up:

Microsoft JScript runtime error: 'keyCode' is null or not an object

This is insanse. This is the page I'm on when it crashses. Does this have something to do with ajax?

<script type="text/javascript">
function onKeyPress (evt)
	var keycode;

	if (window.XMLHttpRequest)
		keycode = evt.keyCode;
		keycode = event.keyCode;



Microsoft JScript runtime error: 'document.getElementById(...)' is null or not an object



I have one text box and that textbox should contain firstname.lastname.

I am doing Client side validation.

I am getting error Microsoft JScript runtime error: 'document.getElementById(...)' is null or not an object.

ASPX code :-

function validateTextBox(str)
         alert(str);// Getting proper value
        if (str.indexOf(".") == -1)
                alert("Username should have period(.) between firstName and LastName like FirstName.LastName or FirstNameMI.LastName");
               // Here i am getting error...
                return false;

Microsoft JScript runtime error: Object doesn't support this property or method



When I am updating dropdown of parent window from popup it shows error JScript runtime error. But I can able to clear the dropdown. When I am adding only the problem is occuring. I have pasted the code below

var ddlVendor = window.opener.aspnetForm.document.getElementById('ctl00_DefaultContent_ddlVendor');

//Clears the state combo box contents.

for (var count = ddlVendor.options.length-1; count >-1; count--)


ddlVendor.options[count] =


var stateNodes = listNode.getElementsByTagName('Table1/UserName');

var stateIds = listNode.getElementsByTagName('Table1/Password');

Microsoft JScript Runtime Error-Cannot Call Response .Write


i am simply doing a searching of records on button click if record found it will be display in gridview pther wise  it will print me a message no value found

but everytime when it execute my Else Block it always throws me this script error how i can resolve it

Currently Using Ajax Update Panel Script Manager C#

my Html

                    <asp:Button ID="Button1" runat="server" Text="Button" onclick="Button1_Click" />
        <asp:UpdatePanel ID="UpdatePanel1" runat="server">
                <asp:GridView ID="GridView1" runat="server" Width="385px">
                <asp:AsyncPostBackTrigger ControlID="Button1" EventName="Click" />
        </asp:UpdatePanel> </td>

My Code Behind

protected void Button1_Clic

Microsoft JScript runtime error: Object required


have code

and i m getting an error( mentioned in title ) on line

browserdetect = textcontainerobj.filters ? "ie" : typeof textcontainerobj.style.MozOpacity == "string" ? "mozilla" : ""

please help 


<%@ Page Language="VB" AutoEventWireup="false" CodeFile="Default3.aspx.vb" Inherits="Default3" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>GFLN - Global Freight & Logistics Network</title>
<!--[if IE 6]>
<script type="text/javascript" src="js/DD_belatedPNG.js"></script>
<link href="css/styles.css" rel="stylesheet" type="text/css"/>
<!-- for left menu-->
<script type="text/javascript">

    var baseopacity = 0

    function showtext(thetext) {
        if (!document.getE

Microsoft JScript runtime error: Sys.WebForms.PageRequestManagerServerErrorException: RAISEERROR


I'm getting this error:

Microsoft JScript runtime error: Sys.WebForms.PageRequestManagerServerErrorException: You cannot add to the repair list until the barcode is added to Inventory first.

 Now the 'You cannot add to the repair list until the barcode is added to Inventory first.' is my own message being returned from

sql server.


I have a datagrid with a new button on it. When the user clicks on the button I insert a blank row in the grid. They then go to edit the record to put info in the grid.

Since the system is a barcode driven system, I check the barcode they entered to make sure it's in the system. If not I throw the message from sql server using the RAISEERROR event.

Here is the partial sql code:

	if not exists(select * from dbo.tblIndentification 
				where Identification_Barcode = @barcode) 
		RAISERROR(50020,11,1)  with NOWAIT
		return -1


Here  is the c# code:

                else if (e.CommandName.Equals("Update"))
                    //for use in conjuction when the user inserts a new row
                    if  (txtCurrentRowBeingEdited.Text=="")

CollapsiblePanelExtender - Microsoft JScript runtime error: Sys.InvalidOperationException js Error:


Dear All,

I am using a Master-detail gridview (gridview inside a gridview) and have a CollapsiblePanelExtender that opens the child gridview.

I have put the CollapsiblePanelExtender in the Itemtemplate of the parent gridview. Hence, for every item in the parent gridview, CollapsiblePanelExtender with duplicate id's are getting generated. I get this js error on load of the page: Microsoft JScript runtime error: Sys.InvalidOperationException: Two components with the same id 'cpe' can't be added to the application.

Below is  my html code:


    <form id="form1" runat="server">

    <ajaxToolkit:ToolkitScriptManager ID="ScriptManager1" runat="server" />

    <div id="dlg" style="width: 700px">

        <asp:Panel ID="pnlDFS" runat="server">

            <asp:GridView ID="gvDFSLinks" Width="100%" AllowPaging="True" AutoGenerateColumns="False"

                runat="server" ShowHeader="False" O

Visual Web Developer 2008 Express - JScript runtime error

I've noticed in Visual Studio 2008 and Visual Web Developer 2008 Express that several, dynamic JScript files are being generated at runtime.  When I run my project in "debug mode," and then I attempt to close the browser, I get the following error: "Microsoft JScript runtime error: Object doesn't support this action" The error occurs in a JS file called "jquery-1.3.2.min.js?77[dynamic].  This file is not part of my project, and I don't know where it resides. In Solution Explorer, under "Script Documents" > "Windows Internet Explorer", there are several other dynamic js files that are only appearing at runtime... What feature is causing these JS files and the JScript runtime error, to be dynamically generated at runtime?    

Modal Popup Extender: Jscript Runtime Error

I have a master detail aspx page with modal popup. The modal popup has a formview with edit and insert options. Whenever I try to show or hide the popup it always gives the following error. If I ignore it just works fine. Any reason why is this error popping up. Once when I deleted all the breakpoints and debugged it, the error did not show up Error:       Microsoft JScript runtime error: SysArgumentNullException: Value cannot be null       Parameter name:elements. I do not where the error occurs. It shows a break some where as follows: Debug Script Section --------------------------- Sys.UI.DomEvent.prototype = {     preventDefault: Sys$UI$DomEvent$preventDefault,     stopPropagation: Sys$UI$DomEvent$stopPropagation } Sys.UI.DomEvent.registerClass('Sys.UI.DomEvent');     $addHandler = Sys.UI.DomEvent.addHandler = function Sys$UI$DomEvent$addHandler(elements, eventName, handler, autoRemove) {     /// <summary locid="M:J#Sys.UI.DomEvent.addHandler" />     /// <param></param>     /// <param></param>     /// <param></param>     /// <param optional="true" mayBeNull

backspace key causes JScript runtime error



I am using combobox from AjaxControlToolKit. If I enter some info in the text portion of my combobox, then click out of it and return to it to change what I typed, using the backspace key, I get a JScript runtime error (null or not an object). This also hapeens if I try to fix the text using the delete key under the same conditions.

Does anyone have an idea of what could be going on here. I am using the most updated version of the AjaxControlToolkit, which is v.3.5, which was released in April or May this year.

Any advice would be really appreciated.




ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend