Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

VBA to add Description property to AVI file

Status
Not open for further replies.

u01jmg3

Technical User
Dec 16, 2005
8
GB
Hi,

Just wondered if anyone could point me in the right direction. I'm trying to create a VBA script to add in a value to the "Description" property field of an AVI file. Basically, I've written a PHP script to retrieve film synopsis info from IMDB given a film title. Now I want to use VBA to add the synopsis to the AVI film. I have a lot of films so I want to do this dynamically.

Any help would be much appreciated. Whilst I'm very good with PHP, I'm very new to VBA!

(Windows 7 64-bit)
 
Assuming you meant VBS instead of VBA, I found this to read extended properties
Code:
Dim arrHeaders(34)

Set objShell = CreateObject("Shell.Application")
Set objFolder = objShell.Namespace("C:\Scripts")

For i = 0 to 33
    arrHeaders(i) = objFolder.GetDetailsOf(objFolder.Items, i)
Next

For Each strFileName in objFolder.Items
    For i = 0 to 33
        Wscript.Echo i & vbtab & arrHeaders(i) _
            & ": " & objFolder.GetDetailsOf(strFileName, i) 
    Next
Next
Source:
Unfortunately, from other links, there does not appear to be an equivalent "SetDetailsOf" method. You might be out of luck.

Jeff
[small][purple]It's never too early to begin preparing for [/purple]International Talk Like a Pirate Day
"The software I buy sucks, The software I write sucks. It's time to give up and have a beer..." - Me[/small]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top