Board index » cppbuilder » Indy (other other) web browser code
Paul
![]() CBuilder Developer |
Paul
![]() CBuilder Developer |
Indy (other other) web browser code2008-06-30 09:35:02 PM cppbuilder3 Having a bit of fun with indy Basically I want to write an app that visits a few differnet web pages and then downloads the source of the page to a text file. I have tried indy and have not had much success, same with TccpWebBrowser Dioes anyone either have a sample of source for the above or a suggestion of an alternate VCL package - pref free as this is just a fun bit of coding |
Remy Lebeau (TeamB)
![]() CBuilder Developer |
2008-07-01 12:40:40 AM
Re:Indy (other other) web browser code
"Paul" < XXXX@XXXXX.COM >wrote in message
QuoteI have tried indy and have not had much success, |
Paul
![]() CBuilder Developer |
2008-07-01 07:13:34 PM
Re:Indy (other other) web browser code
When i call the connect method I get an 11004 exception, this same bit of
code worked in an older version of indy TCP->Host = "www.google.com"; TCP->Port = 80; TCP->Connect(); {smallsort} |
Remy Lebeau (TeamB)
![]() CBuilder Developer |
2008-07-02 12:53:07 AM
Re:Indy (other other) web browser code
"Paul" < XXXX@XXXXX.COM >wrote in message
QuoteWhen i call the connect method I get an 11004 exception TCP->Host = "www.google.com"; To this instead: TCP->Host = "www.google.com"; With that said, you should be using the TIdHTTP component instead of the TIdTCPClient component directly. Then you can do this: AnsiString PageSource = HTTP->Get("www.google.com"); Or this: TFileStream *PageSource = new TFileStream("c:\\some folder\\somefile.html"); HTTP->Get("www.google.com", PageSource); delete PageSource; Quotethis same bit of code worked in an older version of indy Gambit |