Click here to Skip to main content
15,886,079 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
I have fetched data using classnames of div control. The content that is visible on the page is being fetched but there is a popup div whose display property is none. The elements inside this are not being fetched as input type is set to hidden.
My code is as follows:
dynamic div_classes = webBrowser1.Document.Body.GetElementsByTagName("div");
C#
 foreach (HtmlElement d in div_classes)
 {
  if (d.GetAttribute("className") == "persontitle")
     {
     persontitle = d.InnerText;
     txtTitle.Text = persontitle;
     }
//and so on..
}


Immediate help would be really appreciated!!
Thanks
Posted
Updated 23-Jun-14 1:49am
v5
Comments
Thanks7872 23-Jun-14 8:14am    
Why C#? This can easily be done using JQuery/javascript.
Member 10872859 23-Jun-14 8:22am    
Can you please tell me the syntax

1 solution

input type is hidden means its hidden field. You can easily access its value like:
C#
$("#Id_Of_That_Field").val();

If your popup div has class name popup,then syntax goes like this:
C#
$(".popup").html();

Regards..
 
Share this answer
 
v2

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900