COM constants iterable

Constants associated with a COM Object can be accessed by indexing the COM object with the constant name.

Example

local word = sys.COM("Word.Application") local doc = word.Documents:Add() local sel = word.Selection -- Set the Seleciton.Paragraphs.Alignment property to wdAlignParagraphCenter sel.Paragraphs.Alignment = word.wdAlignParagraphCenter