473,386 Members | 1,609 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,386 software developers and data experts.

Detecting the value of an element on a web page

jamesd0142
469 256MB
Apologies if this is not clear, I'm not 100% sure how to ask the question to start with.

On a web page there is a line that reads:

Expand|Select|Wrap|Line Numbers
  1. <div id="attack_alert" style="visibility:hidden;">
  2.  
Now, if I open the web page up in web browser within my vb.net application.

How do I then detect whether the "attack_alert" is:
Expand|Select|Wrap|Line Numbers
  1. 1, <div id="attack_alert" style="visibility:visible;">
  2.  
OR
Expand|Select|Wrap|Line Numbers
  1. 2, <div id="attack_alert" style="visibility:hidden;">
  2.  
Thanks James
Dec 7 '11 #1
2 2112
jamesd0142
469 256MB
Solved this myself in the end.

For future users: the solution:

Expand|Select|Wrap|Line Numbers
  1.  Dim myElement As HtmlElement
  2.         myElement = webbrs.Document.GetElementById("attack_alert")
  3.         Dim value2 As String = myElement.Style
  4.  
Dec 7 '11 #2
jamesd0142
469 256MB
error double post

please delete
Dec 7 '11 #3

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

Similar topics

3
by: foldface | last post by:
Hi Given a web page using frames, is there anyway the left frame can request a page in the right frame and, most importantly, detect when it has fully loaded? Ideally this requires no changes to...
1
by: Paul Cheevers | last post by:
Hi, I've been trying to write some schema to validate the Value element of an Eq element but to no avail. If the Value Element is off type DateTime then the node should be able to contain text...
1
by: JohnJohn | last post by:
Hello. I have developed a VB.NET 2005 web site using .NET Framework 2.0. Does anyone know if there is a way for me to detect when a particular page has been refreshed by means of clicking the...
3
by: brett | last post by:
I have assigned a value to a variable defined in a code behind page. I'd like to display a variable named myvar in the aspx page's <meta http-equiv="refresh" content=myvar> tag. If I put...
0
by: Spondishy | last post by:
Hi, I've developed some code to run in the http pipeline. Part of the code attempts to get the current pages title. A little similar to this: HttpApplication application = sender as...
2
by: =?Utf-8?B?TWlrZQ==?= | last post by:
Greetings, I am trying to find out how to do something that on the surface seems like it should be very simple to do. I have a datagrid with a datatable bound to it using the SetDataBinding...
3
by: sathikbasha | last post by:
hi Please tel me is there any way to set the value to Page Set Up example LEFT ,RIGHT,TOP and BOTTOM using java script..
1
by: Rivka | last post by:
Hello, How can I, from an ASP page, distinguish whether I've arrived to a page from "navigate" (not the asme vitual directory) or whether I'm in the same virtual directory (arrived by...
4
by: daveh551 | last post by:
Okay, I feel like this is probably a stupid question, but... I have accessed sites that are pushing some scam that, when you go to leave the page it will pop up a box saying, "No, don't go, let...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
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
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: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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
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
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
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,...

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.