Views

...

Important:

Quaisquer soluções e/ou desenvolvimento de aplicações pessoais, ou da empresa, que não constem neste Blog podem ser tratados como consultoria freelance.

E-mails

Deixe seu e-mail para receber atualizações...

eBook Promo

Mineração de Dados: Extraindo tabelas de páginas da Web

Mineração de Dados: Extraindo tabelas de páginas da Web


Como importar uma tabela HTML para a planilha do Excel, quando se consulta uma página na Web? Se qualquer site tem dados em forma de tabelas, usaremos a opção Consulta na Web do Excel para importá-lo,usando-o como um navegador. Neste ponto clicamos com o botão direito na Tabela da Web e escolheremos a opção "Exportar para o Microsoft Excel". 

Esta opção de consulta na Web não funcionará corretamente com algum site. Neste artigo veremos como fazer uma Mineração de Dados apenas com o Excel

Este breve artigo explicará como importar o conteúdo HTML. Será atribuído como um objeto HTMLFile com mais opções de recuperação das tags HTML.

Depois de obtermos o conteúdo da página Web, teremos as respectivas tags relacionadas à tabela como <Table>, <TR> e <TD>.

A última etapa será processar cada linha e célula nessa tabela e transferi-la para a Planilha.

Sub HTML_Table_To_Excel()
    Dim htm As Object
    Dim Tr As Object
    Dim Td As Object
    Dim Tab1 As Object

    'Replace the URL of the webpage that you want to download
    Web_URL = VBA.Trim(Sheets(1).Cells(1, 1))

    'Create HTMLFile Object
    Set HTML_Content = CreateObject("htmlfile")

    'Get the WebPage Content to HTMLFile Object
    With CreateObject("msxml2.xmlhttp")
        .Open "GET", Web_URL, False
        .send
        HTML_Content.Body.Innerhtml = .responseText
    End With

    Column_Num_To_Start = 1
    iRow = 2
    iCol = Column_Num_To_Start
    iTable = 0

    'Loop Through Each Table and Download it to Excel in Proper Format
    For Each Tab1 In HTML_Content.getElementsByTagName("table")
        With HTML_Content.getElementsByTagName("table")(iTable)
            For Each Tr In .Rows
                For Each Td In Tr.Cells
                    Sheets(1).Cells(iRow, iCol).Select
                    Sheets(1).Cells(iRow, iCol) = Td.innerText
                    iCol = iCol + 1
                Next Td
                iCol = Column_Num_To_Start
                iRow = iRow + 1
            Next Tr
        End With
        iTable = iTable + 1
        iCol = Column_Num_To_Start
        iRow = iRow + 1
    Next Tab1

    MsgBox "Process Completed"

End Sub


Limitações

Em muitos sites, mesmo o Facebook, Twitter e páginas web, aparecerão tabelas. Mas elas estão incorporadas dentro das tags DIV e SPAN. É melhor usar as APIs do Facebook, Twitter ao invés de apenas confiar nas tags HTML.


Deixe seus comentários, compartilhe este artigo!

brazilsalesforceeffectiveness@gmail.com
✔ Brazil SFE®✔ Brazil SFE®´s Facebook´s Profile  Google+   Author´s Professional Profile  ✔ Brazil SFE®´s Pinterest       ✔ Brazil SFE®´s Tweets

LISTA DE ESTADOS BRASILEIROS: Sigla, Estado, Capital e Região

LISTA DE ESTADOS BRASILEIROS: Sigla, Estado, Capital e Região



Como é útil termos disponível uma tabela pronta para ser conectada em nossa tabela e através de uma simples PROCV ou PROCH resolvermos todos os nossos problemas não é mesmo?





Deixe seus comentários, compartilhe este artigo!

brazilsalesforceeffectiveness@gmail.com
✔ Brazil SFE®✔ Brazil SFE®´s Facebook´s Profile  Google+   Author´s Professional Profile  ✔ Brazil SFE®´s Pinterest       ✔ Brazil SFE®´s Tweets

VBA OFFICE - EXCEL, ACCESS, OUTLOOK, POWERPOINT

VBA OFFICE - EXCEL, ACCESS, OUTLOOK, POWERPOINT


PROJETOS CURTOS OU LONGOS 

Desenvolvo e aprimoro seus Dashboards em MS Excel!

  • DASHBOARDS 
  • SCORECARDS 
  • BSC 
  • REPORTs 
  • Aplicações MS Access  

Conecte suas planilhas ao BI!  


Contate-me: brazilsalesforceeffectiveness@gmail.com





brazilsalesforceeffectiveness@gmail.com

✔ Brazil SFE®Author´s Profile  Google+   Author´s Professional Profile   Pinterest   Author´s Tweets

Férias 2016 - 2017

Férias 2016 - 2017




Sim, vamos tirar alguns dias para descansar, sem atualizações, sem pesquisas. Apenas relaxar um pouco e voltamos logo.

Divirtam-se e nos vemos em Janeiro de 2017!

Alexandra Burke - Hallelujah




Envie seus comentários e sugestões e compartilhe este artigo!

brazilsalesforceeffectiveness@gmail.com

✔ Brazil SFE®✔ Brazil SFE®´s Facebook´s Profile  Google+   Author´s Professional Profile  ✔ Brazil SFE®´s Pinterest       ✔ Brazil SFE®´s Tweets

Index 2016 + de 700 Artigos ✔ VBA Brazil Specialist®

Index 2016 + de 700 Artigos ✔ VBA Brazil Specialist®


Visual Basic for Application
Microsoft Excel

Acesse + de 7000 Artigos

VBA, Gauges, Dashboards, Visual Basic, Access, SQL, Outlook, DAO, Powerpoint, Reports, Data, Business Intelligence, Big Data, Donut Project, Sandwich Project, e-Mails, Infográficos, Quick Reference Card, SQL Server, Shell . . .


Envie seus comentários e sugestões e compartilhe este artigo!

brazilsalesforceeffectiveness@gmail.com

✔ Brazil SFE®✔ Brazil SFE®´s Facebook´s Profile  Google+   Author´s Professional Profile  ✔ Brazil SFE®´s Pinterest       ✔ Brazil SFE®´s Tweets









Excel 2016 Power Programming with VBA

Excel 2016 Power Programming with VBA


















Excel 2016 Power Programming with VBA is fully updated to cover all the latest tools and tricks of Excel 2016. Encompassing an analysis of Excel application development and a complete introduction to Visual Basic for Applications (VBA), this comprehensive book presents all of the techniques you need to develop both large and small Excel applications. Over 800 pages of tips, tricks, and best practices shed light on key topics, such as the Excel interface, file formats, enhanced interactivity with other Office applications, and improved collaboration features. In addition to the procedures, tips, and ideas that will expand your capabilities, this resource provides you with access to over 100 online example Excel workbooks and the Power Utility Pak, found on the Mr. Spreadsheet website.

Understanding how to leverage VBA to improve your Excel programming skills can enhance the quality of deliverables that you produce—and can help you take your career to the next level.

  • Explore fully updated content that offers comprehensive coverage through over 900 pages of tips, tricks, and techniques
  • Leverage templates and worksheets that put your new knowledge in action, and reinforce the skills introduced in the text
  • Access online resources, including the Power Utility Pak, that supplement the content
  • Improve your capabilities regarding Excel programming with VBA, unlocking more of your potential in the office

Excel 2016 Power Programming with VBA is a fundamental resource for intermediate to advanced users who want to polish their skills regarding spreadsheet applications using VBA.


Envie seus comentários e sugestões e compartilhe este artigo!

brazilsalesforceeffectiveness@gmail.com

✔ Brazil SFE®✔ Brazil SFE®´s Facebook´s Profile  Google+   Author´s Professional Profile  ✔ Brazil SFE®´s Pinterest       ✔ Brazil SFE®´s Tweets

Learn Excel 2016 Expert Skills with The Smart Method: Courseware Tutorial teaching Advanced Techniques

Learn Excel 2016 Expert Skills with The Smart Method: Courseware Tutorial teaching Advanced Techniques















This Excel 2016 book is for users who want to upgrade their basic Excel 2016 skills to true expert level. It will teach you to master all of Excel 2016's advanced features. If you are an absolute beginner you need our Excel 2016 Essential Skills book.

The book is very, very different to any other computer book you have ever read. The Smart Method provides an entirely new and better way to master advanced Excel 2016 features. Here's just four of the many ways in which the book is unique:
  • This book won't waste your time by teaching basic Excel 2016 skills that you already know. All of that material is covered already in our beginner's Excel 2016 Essential Skills book. By assuming that you are already able to use Excel's basic features, far more ground can be covered.
  • Instruction is logically structured into sessions and lessons. While this makes the book ideal for self-instruction, you can also use it to run your own, highly effective, adult training courses.
  • Every lesson is presented on two facing sheets of A4 paper (the pages are much bigger than in any other Excel book).
  • Each lesson has a sample file that models a real-world business problem. You'll immediately appreciate the value and relevance of each skill you learn.
Advanced concepts are explained without needless technical jargon.  Everything is concisely described in a simple, no-nonsense way.  No matter what your background is, this book will enable you to master Excel 2016's most advanced features in a fraction of the time needed when learning from conventional text books.

Here is a small selection from the many advanced Excel skills you will learn::
  • Master dynamic tables using automatic, manual, qualified and unqualified structured table references
  • Use advanced filters to apply complex logical criteria
  • Use Excel's Subtotal feature to create both regular and nested subtotals
  • Use formula-driven validations to enforce complex business rules
  • Implement a hyperlink-based navigation system to allow users to easily navigate large workbooks
  • Create beautiful interactive forms using checkbox, combo box, command button, text box and option button controls
  • Record macros with both absolute and relative references
  • Use slicers to allow touch-screen users to quickly filter Pivot Tables by multiple criteria
  • Understand primary and foreign keys and use them to create both one-to-many and many-to-many relationships
  • Understand OLAP pivot tables and use them to analyze data residing in a data model
  • Create a 3D Map video tour with multiple scenes using both single and multiple visualization layers
  • Use Get  & Transform queries to extract, clean and combine data from Web Pages, Databases and Worksheets
  • Use Get & Transform to create a de-normalized data extract from a multi-table relational database


Envie seus comentários e sugestões e compartilhe este artigo!

brazilsalesforceeffectiveness@gmail.com

✔ Brazil SFE®✔ Brazil SFE®´s Facebook´s Profile  Google+   Author´s Professional Profile  ✔ Brazil SFE®´s Pinterest       ✔ Brazil SFE®´s Tweets

eBooks VBA na AMAZOM.com.br

LinkWithinBrazilVBAExcelSpecialist

Related Posts Plugin for WordPress, Blogger...

Vitrine