Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium


Updating a childNode.text value

Posted on 2005-03-11
Medium Priority
Last Modified: 2008-02-01
The code below is nearly is fine exept for the bit in between '::::::' have a look below for more info:

What I want to do is update this node value to the current date and time sounds easy.....


above is ok its the bit below that causes the problem, I dont even know if it is right!!!

Error message is: 800a01a8|Object_required:_'0'


userkeepuseraliveobjchildNodes[0].text = now()


and then save the file which I have.

p.s. using MSXML 4.0 and asp for the script.

Question by:scanet

Accepted Solution

guru_k earned 500 total points
ID: 13523720

first, there is a simple syntax error, you forgot the DOT before childNodes:

userkeepuseraliveobj.childNodes[0].text = now()

Since I am not familiar with ASP I just can give you some generic DOM specification know how. The DOM specification, Node interface, says that the property nodeValue should be used.

So in theory, like this:

userkeepuseraliveobj.childNodes[0].nodeValue = now()

Additionally the DOM specification for CharacterData says:

userkeepuseraliveobj.childNodes[0].data = now()

One of those should work.


Author Comment

ID: 13523755
Thanks, Im always doing sillys.

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Browsing the questions asked to the Experts of this forum, you will be amazed to see how many times people are headaching about monster regular expressions (regex) to select that specific part of some HTML or XML file they want to extract. The examp…
Many times as a report developer I've been asked to display normalized data such as three rows with values Jack, Joe, and Bob as a single comma-separated string such as 'Jack, Joe, Bob', and vice versa.  Here's how to do it. 
This video shows how to quickly and easily deploy an email signature for all users in Office 365 and prevent it from being added to replies and forwards. (the resulting signature is applied on the server level in Exchange Online) The email signat…
How can you see what you are working on when you want to see it while you to save a copy? Add a "Save As" icon to the Quick Access Toolbar, or QAT. That way, when you save a copy of a query, form, report, or other object you are modifying, you…

571 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question