Get data from inside a div/table












0















@QHarr answered my question here Get the value inside Nested Tables and Divs using VBA regarding the values inside the nested tables and it worked great. Now I realize that not all the data are getting pulled. Here is what I thought my HTML was:



<body style="BORDER: 0px; MARGIN: 0px; PADDING: 0px">
<DIV style="HEIGHT:100%;WIDTH:100%;" class="ap">
<TABLE CELLSPACING="0" CELLPADDING="0">
<TR>
// This TD was solved by @QHarr
<TD ID="oReportCell">
Some tables and values. @QHarr already solved this part
</TD>
</TR>
</TABLE>

</DIV>

</body>


But when I realized that not all the data were pulling I checked the HTML I found out that not all the data are inside the ID="oReportCell"
So, HTML looks like this:



<body style="BORDER: 0px; MARGIN: 0px; PADDING: 0px">
<DIV style="HEIGHT:100%;WIDTH:100%;" class="ap">
<TABLE CELLSPACING="0" CELLPADDING="0">
<TR>
// This TD was solved by @QHarr

<TD ID="oReportCell">
Some tables and values. @QHarr already solved this part
</TD>
</TR>
</TABLE>

</DIV>

<DIV style="HEIGHT:100%;WIDTH:100%;" class="ap">
<TABLE CELLSPACING="0" CELLPADDING="0">
<TR>
<TD ID="oReportCell">
Some tables and values.
</TD>
</TR>
</TABLE>




<DIV style="HEIGHT:100%;WIDTH:100%;" class="ap">
<TABLE CELLSPACING="0" CELLPADDING="0">
<TR>
<TD ID="oReportCell">
Some tables and values.
</TD>
</TR>
</TABLE>




</body>


They are 14 of Class="ap", and when the code is executed sometime it gets the first one. Sometime the second and so on. It doesn't get all the value.



I need to get everything that is inside class ="a92" and class="a69"



here is the full html:
I can't use pastebin due to the size of the file:



enter link description here



here is one of the .ap



enter link description here










share|improve this question

























  • For the example shown above, it seems ap is not within #oReportCell and in fact the selector becomes .ap, #oReportCell . Selecting for everything inside a92 and a69 would be querySelectorAll(".a92, .a69")

    – QHarr
    Nov 22 '18 at 5:50













  • @QHarr I updated the link. You have to look at view source. #oReportCell is only present in the first .ap, not all of them.Also, I added .ap pastebin

    – Sifaks Agizul
    Nov 22 '18 at 6:20













  • We need the actual html not the view source. If in chrome press F12 then select the top html tag and right click copy element

    – QHarr
    Nov 22 '18 at 6:35











  • @QHarr That's how I did it the first place. I pasted it inside a file, rename its extension to html, and I uploaded it. Looking at the view page source gives me exactly what pressing F12 does.

    – Sifaks Agizul
    Nov 22 '18 at 6:55











  • They may be different. codebyamir.com/blog/view-source-vs-inspect-element

    – QHarr
    Nov 22 '18 at 7:06


















0















@QHarr answered my question here Get the value inside Nested Tables and Divs using VBA regarding the values inside the nested tables and it worked great. Now I realize that not all the data are getting pulled. Here is what I thought my HTML was:



<body style="BORDER: 0px; MARGIN: 0px; PADDING: 0px">
<DIV style="HEIGHT:100%;WIDTH:100%;" class="ap">
<TABLE CELLSPACING="0" CELLPADDING="0">
<TR>
// This TD was solved by @QHarr
<TD ID="oReportCell">
Some tables and values. @QHarr already solved this part
</TD>
</TR>
</TABLE>

</DIV>

</body>


But when I realized that not all the data were pulling I checked the HTML I found out that not all the data are inside the ID="oReportCell"
So, HTML looks like this:



<body style="BORDER: 0px; MARGIN: 0px; PADDING: 0px">
<DIV style="HEIGHT:100%;WIDTH:100%;" class="ap">
<TABLE CELLSPACING="0" CELLPADDING="0">
<TR>
// This TD was solved by @QHarr

<TD ID="oReportCell">
Some tables and values. @QHarr already solved this part
</TD>
</TR>
</TABLE>

</DIV>

<DIV style="HEIGHT:100%;WIDTH:100%;" class="ap">
<TABLE CELLSPACING="0" CELLPADDING="0">
<TR>
<TD ID="oReportCell">
Some tables and values.
</TD>
</TR>
</TABLE>




<DIV style="HEIGHT:100%;WIDTH:100%;" class="ap">
<TABLE CELLSPACING="0" CELLPADDING="0">
<TR>
<TD ID="oReportCell">
Some tables and values.
</TD>
</TR>
</TABLE>




</body>


They are 14 of Class="ap", and when the code is executed sometime it gets the first one. Sometime the second and so on. It doesn't get all the value.



I need to get everything that is inside class ="a92" and class="a69"



here is the full html:
I can't use pastebin due to the size of the file:



enter link description here



here is one of the .ap



enter link description here










share|improve this question

























  • For the example shown above, it seems ap is not within #oReportCell and in fact the selector becomes .ap, #oReportCell . Selecting for everything inside a92 and a69 would be querySelectorAll(".a92, .a69")

    – QHarr
    Nov 22 '18 at 5:50













  • @QHarr I updated the link. You have to look at view source. #oReportCell is only present in the first .ap, not all of them.Also, I added .ap pastebin

    – Sifaks Agizul
    Nov 22 '18 at 6:20













  • We need the actual html not the view source. If in chrome press F12 then select the top html tag and right click copy element

    – QHarr
    Nov 22 '18 at 6:35











  • @QHarr That's how I did it the first place. I pasted it inside a file, rename its extension to html, and I uploaded it. Looking at the view page source gives me exactly what pressing F12 does.

    – Sifaks Agizul
    Nov 22 '18 at 6:55











  • They may be different. codebyamir.com/blog/view-source-vs-inspect-element

    – QHarr
    Nov 22 '18 at 7:06
















0












0








0








@QHarr answered my question here Get the value inside Nested Tables and Divs using VBA regarding the values inside the nested tables and it worked great. Now I realize that not all the data are getting pulled. Here is what I thought my HTML was:



<body style="BORDER: 0px; MARGIN: 0px; PADDING: 0px">
<DIV style="HEIGHT:100%;WIDTH:100%;" class="ap">
<TABLE CELLSPACING="0" CELLPADDING="0">
<TR>
// This TD was solved by @QHarr
<TD ID="oReportCell">
Some tables and values. @QHarr already solved this part
</TD>
</TR>
</TABLE>

</DIV>

</body>


But when I realized that not all the data were pulling I checked the HTML I found out that not all the data are inside the ID="oReportCell"
So, HTML looks like this:



<body style="BORDER: 0px; MARGIN: 0px; PADDING: 0px">
<DIV style="HEIGHT:100%;WIDTH:100%;" class="ap">
<TABLE CELLSPACING="0" CELLPADDING="0">
<TR>
// This TD was solved by @QHarr

<TD ID="oReportCell">
Some tables and values. @QHarr already solved this part
</TD>
</TR>
</TABLE>

</DIV>

<DIV style="HEIGHT:100%;WIDTH:100%;" class="ap">
<TABLE CELLSPACING="0" CELLPADDING="0">
<TR>
<TD ID="oReportCell">
Some tables and values.
</TD>
</TR>
</TABLE>




<DIV style="HEIGHT:100%;WIDTH:100%;" class="ap">
<TABLE CELLSPACING="0" CELLPADDING="0">
<TR>
<TD ID="oReportCell">
Some tables and values.
</TD>
</TR>
</TABLE>




</body>


They are 14 of Class="ap", and when the code is executed sometime it gets the first one. Sometime the second and so on. It doesn't get all the value.



I need to get everything that is inside class ="a92" and class="a69"



here is the full html:
I can't use pastebin due to the size of the file:



enter link description here



here is one of the .ap



enter link description here










share|improve this question
















@QHarr answered my question here Get the value inside Nested Tables and Divs using VBA regarding the values inside the nested tables and it worked great. Now I realize that not all the data are getting pulled. Here is what I thought my HTML was:



<body style="BORDER: 0px; MARGIN: 0px; PADDING: 0px">
<DIV style="HEIGHT:100%;WIDTH:100%;" class="ap">
<TABLE CELLSPACING="0" CELLPADDING="0">
<TR>
// This TD was solved by @QHarr
<TD ID="oReportCell">
Some tables and values. @QHarr already solved this part
</TD>
</TR>
</TABLE>

</DIV>

</body>


But when I realized that not all the data were pulling I checked the HTML I found out that not all the data are inside the ID="oReportCell"
So, HTML looks like this:



<body style="BORDER: 0px; MARGIN: 0px; PADDING: 0px">
<DIV style="HEIGHT:100%;WIDTH:100%;" class="ap">
<TABLE CELLSPACING="0" CELLPADDING="0">
<TR>
// This TD was solved by @QHarr

<TD ID="oReportCell">
Some tables and values. @QHarr already solved this part
</TD>
</TR>
</TABLE>

</DIV>

<DIV style="HEIGHT:100%;WIDTH:100%;" class="ap">
<TABLE CELLSPACING="0" CELLPADDING="0">
<TR>
<TD ID="oReportCell">
Some tables and values.
</TD>
</TR>
</TABLE>




<DIV style="HEIGHT:100%;WIDTH:100%;" class="ap">
<TABLE CELLSPACING="0" CELLPADDING="0">
<TR>
<TD ID="oReportCell">
Some tables and values.
</TD>
</TR>
</TABLE>




</body>


They are 14 of Class="ap", and when the code is executed sometime it gets the first one. Sometime the second and so on. It doesn't get all the value.



I need to get everything that is inside class ="a92" and class="a69"



here is the full html:
I can't use pastebin due to the size of the file:



enter link description here



here is one of the .ap



enter link description here







excel vba excel-vba






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Nov 22 '18 at 6:13







Sifaks Agizul

















asked Nov 22 '18 at 0:47









Sifaks AgizulSifaks Agizul

2817




2817













  • For the example shown above, it seems ap is not within #oReportCell and in fact the selector becomes .ap, #oReportCell . Selecting for everything inside a92 and a69 would be querySelectorAll(".a92, .a69")

    – QHarr
    Nov 22 '18 at 5:50













  • @QHarr I updated the link. You have to look at view source. #oReportCell is only present in the first .ap, not all of them.Also, I added .ap pastebin

    – Sifaks Agizul
    Nov 22 '18 at 6:20













  • We need the actual html not the view source. If in chrome press F12 then select the top html tag and right click copy element

    – QHarr
    Nov 22 '18 at 6:35











  • @QHarr That's how I did it the first place. I pasted it inside a file, rename its extension to html, and I uploaded it. Looking at the view page source gives me exactly what pressing F12 does.

    – Sifaks Agizul
    Nov 22 '18 at 6:55











  • They may be different. codebyamir.com/blog/view-source-vs-inspect-element

    – QHarr
    Nov 22 '18 at 7:06





















  • For the example shown above, it seems ap is not within #oReportCell and in fact the selector becomes .ap, #oReportCell . Selecting for everything inside a92 and a69 would be querySelectorAll(".a92, .a69")

    – QHarr
    Nov 22 '18 at 5:50













  • @QHarr I updated the link. You have to look at view source. #oReportCell is only present in the first .ap, not all of them.Also, I added .ap pastebin

    – Sifaks Agizul
    Nov 22 '18 at 6:20













  • We need the actual html not the view source. If in chrome press F12 then select the top html tag and right click copy element

    – QHarr
    Nov 22 '18 at 6:35











  • @QHarr That's how I did it the first place. I pasted it inside a file, rename its extension to html, and I uploaded it. Looking at the view page source gives me exactly what pressing F12 does.

    – Sifaks Agizul
    Nov 22 '18 at 6:55











  • They may be different. codebyamir.com/blog/view-source-vs-inspect-element

    – QHarr
    Nov 22 '18 at 7:06



















For the example shown above, it seems ap is not within #oReportCell and in fact the selector becomes .ap, #oReportCell . Selecting for everything inside a92 and a69 would be querySelectorAll(".a92, .a69")

– QHarr
Nov 22 '18 at 5:50







For the example shown above, it seems ap is not within #oReportCell and in fact the selector becomes .ap, #oReportCell . Selecting for everything inside a92 and a69 would be querySelectorAll(".a92, .a69")

– QHarr
Nov 22 '18 at 5:50















@QHarr I updated the link. You have to look at view source. #oReportCell is only present in the first .ap, not all of them.Also, I added .ap pastebin

– Sifaks Agizul
Nov 22 '18 at 6:20







@QHarr I updated the link. You have to look at view source. #oReportCell is only present in the first .ap, not all of them.Also, I added .ap pastebin

– Sifaks Agizul
Nov 22 '18 at 6:20















We need the actual html not the view source. If in chrome press F12 then select the top html tag and right click copy element

– QHarr
Nov 22 '18 at 6:35





We need the actual html not the view source. If in chrome press F12 then select the top html tag and right click copy element

– QHarr
Nov 22 '18 at 6:35













@QHarr That's how I did it the first place. I pasted it inside a file, rename its extension to html, and I uploaded it. Looking at the view page source gives me exactly what pressing F12 does.

– Sifaks Agizul
Nov 22 '18 at 6:55





@QHarr That's how I did it the first place. I pasted it inside a file, rename its extension to html, and I uploaded it. Looking at the view page source gives me exactly what pressing F12 does.

– Sifaks Agizul
Nov 22 '18 at 6:55













They may be different. codebyamir.com/blog/view-source-vs-inspect-element

– QHarr
Nov 22 '18 at 7:06







They may be different. codebyamir.com/blog/view-source-vs-inspect-element

– QHarr
Nov 22 '18 at 7:06














0






active

oldest

votes











Your Answer






StackExchange.ifUsing("editor", function () {
StackExchange.using("externalEditor", function () {
StackExchange.using("snippets", function () {
StackExchange.snippets.init();
});
});
}, "code-snippets");

StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "1"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});

function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});


}
});














draft saved

draft discarded


















StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53422436%2fget-data-from-inside-a-div-table%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown

























0






active

oldest

votes








0






active

oldest

votes









active

oldest

votes






active

oldest

votes
















draft saved

draft discarded




















































Thanks for contributing an answer to Stack Overflow!


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53422436%2fget-data-from-inside-a-div-table%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

Paul Cézanne

UIScrollView CustomStickyHeader Resize height generates problems when scroll is too fast

Angular material date-picker (MatDatepicker) auto completes the date on focus out