Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. How about this...

How about this...

Scheduled Pinned Locked Moved C / C++ / MFC
comoophelptutorial
3 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • B Offline
    B Offline
    bilas
    wrote on last edited by
    #1

    A lot of people know class CHtmlView. I had found pretty functions FIndText() and FindText2(), written by Marc Richarme (http://www.codeproject.com/miscctrl/CHtmlView\_Search/CHtmlView\_Search\_demo.zip), that allow to find text on loaded(!) web-page. Now I'm making project. One of main its functions is finding text on several(!) pages. I do not know any other way to do it excepting using function FindText2() ( or FindText() ). Actually, it is possible to find text in several web-pages, using, for example, FindText2() for every page separately. But this function can't be applied until web-document isn't loaded. So, I decided to organize cycle. Each page will be loaded in every other cycle. I mean something like this (in abstraction): for (int i=0; iNavigate2( _urls[i], NULL, NULL ); //To load web-page with address _urls[i] that has type CString; .... //Now I call function OnSearch(), that calls function FindText2(); //then I remember url of every page, on witch the concrete text was found (that is all I need) ... } My problem is concluded in follow: the FindText2() function in my code called every time before new web-page will be loaded completely. That's why FindText2() works with old page-url, finding text on it :(. Having poor English level, I repeat: FindText2() forestalls loading page. So, I would like to know have can I define when my page is loaded, and then I'll call for FindText2(). Thanks in advance, I tried to explaine my problem very exactly.

    N 1 Reply Last reply
    0
    • B bilas

      A lot of people know class CHtmlView. I had found pretty functions FIndText() and FindText2(), written by Marc Richarme (http://www.codeproject.com/miscctrl/CHtmlView\_Search/CHtmlView\_Search\_demo.zip), that allow to find text on loaded(!) web-page. Now I'm making project. One of main its functions is finding text on several(!) pages. I do not know any other way to do it excepting using function FindText2() ( or FindText() ). Actually, it is possible to find text in several web-pages, using, for example, FindText2() for every page separately. But this function can't be applied until web-document isn't loaded. So, I decided to organize cycle. Each page will be loaded in every other cycle. I mean something like this (in abstraction): for (int i=0; iNavigate2( _urls[i], NULL, NULL ); //To load web-page with address _urls[i] that has type CString; .... //Now I call function OnSearch(), that calls function FindText2(); //then I remember url of every page, on witch the concrete text was found (that is all I need) ... } My problem is concluded in follow: the FindText2() function in my code called every time before new web-page will be loaded completely. That's why FindText2() works with old page-url, finding text on it :(. Having poor English level, I repeat: FindText2() forestalls loading page. So, I would like to know have can I define when my page is loaded, and then I'll call for FindText2(). Thanks in advance, I tried to explaine my problem very exactly.

      N Offline
      N Offline
      Neville Franks
      wrote on last edited by
      #2

      Have a look at: OnDocumentComplete(). Neville Franks, Author of ED for Windows www.getsoft.com and Surfulater www.surfulater.com "Save what you Surf"

      B 1 Reply Last reply
      0
      • N Neville Franks

        Have a look at: OnDocumentComplete(). Neville Franks, Author of ED for Windows www.getsoft.com and Surfulater www.surfulater.com "Save what you Surf"

        B Offline
        B Offline
        bilas
        wrote on last edited by
        #3

        I'v just tried. But have no success. I decided to search for text using direct reading from file. Maybe you know, is there any class to organize searching in *.txt file for concrete text? Thank you for answering:)

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups