Set document properties in Acrobat

Hi
What I’m tring to do is open a PDF, get the title of the file, stick it in the “Title” field of document properties and save the file. The only thing I’m stuck on is how you insert something new back into the “title” field. E.g.,

tell application "Adobe Acrobat Professional"
	set theTitle to the name of document 1
	set current_document to document 1
	set doc_title to get info of current_document key "Title" -- it's no problem retrieving this value, but how do you set it?
	tell current_document
		save to ((path to desktop as string) & theTitle)
	end tell
	close document 1
end tell

Any help greatly appreciated!!

Hi,

there’s also a set info command

set info (verb)Set a key/value string pair in the document’s Info dictionary. (from Acrobat Viewer Suite)
Command Syntax:
set info reference ¬
key unicode text ¬
value unicode text

Parameters:
Parameter Required Type Description
direct parameter optional reference The document whose info dictionary is to be modified.
key required unicode text The key under which the string value is to be stored.
value required unicode text The value to be stored.

That’s great - thanks for that, I should have spotted it.