64-bit VISTA
Python 3.1
from urllib import request
a = request.urlopen('http://www.marketwatch.com/investing/currency/CUR_USDYEN').read(20500)
b = a[19000:20500]
idx_pricewrap = b.find('pricewrap')
context = b[idx_pricewrap:idx_pricewrap+80]
idx_bgLast = context.find('bgLast')
rate = context[idx_bgLast+8:idx_bgLast+15]
print(rate)
Traceback (most recent call last): File "c:\P31Working\test_urllib.py", line 4, in idx_pricewrap = b.find('pricewrap') TypeError: expected an object with the buffer interface Process terminated with an exit code of 1
I have NO idea what that error means.
Please help.