This is the first time to use python and need to import htql
when i run this code:
page="<a href=a.html>1</a><a href=b.html>2</a><a href=c.html>3</a>";
for url, text in htql.HTQL(page, query):
The problem of the questioner is he followed installation instructions from HTQL PDF-manual named Hyper-Text Query Language COM Interface, which obviously describes library setup for COM (Component Object Model by Microsoft), proposing
regsvr32 <path-to-dll>. Intended to be used within win32-infrastructure aware applications first place
While there are means to use COM from within python (e.g. via pywin32 and others), it's not common method python script expects.
Proper solution is to follow instructions from HTQL home page, suggesting:
Windows binaries: Download the htql.zip and extract "htql.pyd" to the Python's DLLs directory, such as in 'C:\Python27\DLLs\' or 'C:\Python32\DLLs\'.
to install precompiled python .pyd module within python libraries search path