LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

HTML Source

Hi,

I am using a Microsoft activeX internet controls to bring up a web page, I then need to parse through the HTML source code and extract some data.
How can I grab the HTML source any ideas??

Thanks
James


0 Kudos
Message 1 of 21
(6,621 Views)
Can you use  View>>Source? Alternatively you can use FTP if you have FTP access to the site.

Message Edited by Jattie on 09-13-2005 07:58 AM

Jattie van der Linde
Engineering Manager, Software & Automation
TEL Magnetic Solutions Ltd
0 Kudos
Message 2 of 21
(6,598 Views)
I want to be able to parse through the HTML so view source doesn't really help, need to extract the HTML source from within the my code.

Message 3 of 21
(6,595 Views)
Save the file content to disk and open the file as a txt file and browse through it.
Jattie van der Linde
Engineering Manager, Software & Automation
TEL Magnetic Solutions Ltd
0 Kudos
Message 4 of 21
(6,586 Views)

Hello James,

The easiest way to get the contents of a webpage is to use DataSocket.  With the DS_Open and DS_OpenEx function calls in CVI, you can connect to a URL and read it's contents.  Take a look at the example posted on the following thread.  It demonstrates how to use the Datasocket functions to return the html source of a webpage.

Thanks.

Wendy L
LabWindows/CVI Developer Newsletter
Message 5 of 21
(6,575 Views)
Thanks Wendy that's the solution I was looking for.

James
0 Kudos
Message 6 of 21
(6,556 Views)
Hello,
I've got a linker problem with the given example (copy attached).
The error is:
Undefined symbol '_DS_Open@20' referenced in "dsweb.c".
Undefined symbol '_DS_DiscardObjHandle@4' referenced in "dsweb.c".
Undefined symbol '_DS_GetDataValue@24' referenced in "dsweb.c".

Can someone help me to find a solution? I need to fix the problem quickly to work forward.

best regards
Klaas
0 Kudos
Message 7 of 21
(6,425 Views)
To run this example you must load the DataSocket instrument located in <cvidir>\toolslib\datasock. You can either load it in the Instrument menu or in the Library menu.


Proud to use LW/CVI from 3.1 on.

My contributions to the Developer Community
________________________________________
If I have helped you, why not giving me a kudos?
0 Kudos
Message 8 of 21
(6,418 Views)
That's it.
Thanks
0 Kudos
Message 9 of 21
(6,418 Views)
Hello,

i have a silly problem. I wrote an program to read out the html source of a user specified url and save it to hard disk.
That program works fine, but now it doesn't work anymore. I realized it nearly the same way as its done in the example dsweb.prj.
When I try this example it works once but not twice. As I tried to debug I saw that the datasocket there is no event which is updating the data ("DS_EVENT_DATAUPDATED"). There are some DS_EVENT_STATUSUPDATED events. As I said before, the first time it works and than never again.

The funny thing is, that when I went step by step (debug phase F8) through the program, than it works. I shut down the firewall. How can I solve the problem. It seems to have something to do with my computer or internet connection? But I am pretty sure that I havn't change something on my computer.


Pleas help me I am a bit confused.

Thanks Michael
0 Kudos
Message 10 of 21
(5,768 Views)