[Dialog] Need help to fine tune the dialog.

With the helps from this board, I managed to create a simple dialog box to ask the user to enter the page range for exporting ID files to PDF.

tell application "Adobe InDesign CS3"
	activate
	set myDialog to make dialog
	tell myDialog
		set name to "Export PDF"
		tell (make dialog column)
			tell (make border panel)
				tell (make radiobutton group)
					set myRangeButton to make radiobutton control with properties {static label:"Range from page "}
					make radiobutton control with properties {static label:"All", checked state:true}
				end tell
				set myStartPageInput to make integer editbox with properties {min width:35}
				make static texts with properties {static label:"to page"}
				set myEndPageInput to make integer editbox with properties {min width:35}
			end tell
		end tell
	end tell
	show myDialog
	destroy myDialog
end tell

As you can see from the script, what the user has to do now, is to click the top button manually before or after he has input the page range “ which I felt it is unnecessarily.

I would like to improve it by trigger the top radiobutton as long as the user does input the page range in the editbox (like those professional applications do), but I could not be able to figure it out.

Please advise. Thanks!

Unfortunately ID Dialogs are not that complex and do not support “events” so I don’t know of a way to do auto update elements like that. For dialogs like this I have moved to AppleScript Studio for the script which does allow you to create dialogs with “change” events that can update other elements as well as binding for storing and accessing data more efficiently. Another benefit is cleaner code and a more precise interface than you can get with ID dialogs.

Anyway, thanks a lot for your kind reply, Jerome!