Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Listing html Title tag in a spreadsheet.
I have reached the end of my limited knowledge.
I am dealing with a large number of html files where the file name bares no resemblance to the contents. I can put a list of all the files in the column B of my spreadsheet. What I need to do is put the text between the <title and </title tags in the next column. I am running excel 2002, but if this could work for 2000 so I could use it at work it would be cool. Regards Steve the dropbear |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Listing html Title tag in a spreadsheet.
Following should do it..
...change directory before running it Sub ReadTitles() Dim wb As Workbook, rng As Range, r&, sFile$ Set rng = ActiveCell sFile = Dir("*.htm*") Application.ScreenUpdating = False While sFile < "" Set wb = Workbooks.Open(sFile) r = r + 1 rng(r, 1) = wb.Name rng(r, 2) = wb.BuiltinDocumentProperties("Title") wb.Close sFile = Dir Wend Application.ScreenUpdating = True End Sub keepITcool < email : keepitcool chello nl (with @ and .) < homepage: http://members.chello.nl/keepitcool "Gustavus Vasa" wrote: I have reached the end of my limited knowledge. I am dealing with a large number of html files where the file name bares no resemblance to the contents. I can put a list of all the files in the column B of my spreadsheet. What I need to do is put the text between the <title and </title tags in the next column. I am running excel 2002, but if this could work for 2000 so I could use it at work it would be cool. Regards Steve the dropbear |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Listing Names in a spreadsheet | Excel Discussion (Misc queries) | |||
HTML controls in spreadsheet | New Users to Excel | |||
Title listing... | Excel Discussion (Misc queries) | |||
Want file title listing as in Excel 5.0 File>Find | Excel Discussion (Misc queries) | |||
Listing the contents of a directory in a spreadsheet | Excel Programming |