473,396 Members | 1,590 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

How to parse through the HTML and get the values.

3
Hi ,
I have a javascript in which i am able to get the HTML view of the datagrid(which has 4 row and 4 column),
It shows the each and every textbox and columns in table format,
I used the

var len1=obj.parentElement.parentElement.parentElement .parentElement.innerHTML;
alert("first:"+len1);

to see that HTML view,
Here obj is got from the event in ASP.Net,

I want to know how can i get the value from the HTML page,
When i used the firstElement or nextElement with the parent Element,
the error is that "null or not an object",

What type of command i should use to parse through the HTML,


Thanks
Jun 8 '07 #1
1 1356
gits
5,390 Expert Mod 4TB
hi ...

you may use:

document.getElementById(id) - for getting a ref to an element (node)
node.nextSibling - gives you the 'right' neighbor
node.previousSibling - gives you the 'left' neighbor
node.parentNode - gives you the parent
node.firstChild - the first child node
node.lastChild - the last child node
...

have a look for dom-scripting, -navigating ... good link is here:

http://www.w3schools.com/htmldom/default.asp

kind regards ...
Jun 8 '07 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: josh dismukes | last post by:
/// here is the code i'm getting a parse error on the last line of the code which /// is </html> any help will be much appreciated. <?php session_start ();
6
by: Dave Kuhlman | last post by:
Suppose that I have content that looks like what I've included at the end of this message. Is there something in the standard Python library that will help me parse it, break into the parts...
11
by: Karim | last post by:
I am looking for the easiest way to parse a float number. X.Y where X=>0 and X <=5 and Y = 0 or Y = 5 e.g. the number should be one of the following 1 1.0 1.5 2 2.0 2.5 etc. I tired using...
6
by: Ehartwig | last post by:
I recently created a script for user verification, solved my emailing issues, and then re-created the script in order to work well with the new PHP 5 that I installed on my server. After...
3
by: Ken Bush | last post by:
How can I write an update query that removes part of a field? Like if I have a field with values such as 8/3/68 (a birthday obviously) and I need to put values in a new column but I need...
22
by: Illya Havsiyevych | last post by:
Hello How easily parse VB/VBA code by VB/VBA code ? Is any ready solutions ? Thank's, illya
5
by: tony collier | last post by:
I have ..... enum day {monday, tuesday, wednesday}; myArray=5; i=(int)Enum.Parse(typeof(day), wednesday);
8
by: Uros | last post by:
Hello! I have problem with my function and I can find what's wrong. WARNING: Error occurred while executing PL/pgSQL function fn_insert_entry_pending WARNING: line 26 at SQL statement...
6
by: trevor | last post by:
Incorrect values when using float.Parse(string) I have discovered a problem with float.Parse(string) not getting values exactly correct in some circumstances(CSV file source) but in very similar...
1
AdrianH
by: AdrianH | last post by:
Assumptions I am assuming that you know or are capable of looking up the functions I am to describe here and have some remedial understanding of C programming. FYI Although I have called this...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.