报错:failed to create WIN32OLE object from `Word.Application' HRESULT error code:0x800401f0
代码:require 'win32ole' word = WIN32OLE.new('Word.Application') word.visible=true #是否打开文件 word.Documents.Add() for i in(0..100) word.Selection.Font.Size=12 word.Selection.Font.ColorIndex = 2 word.Selection.TypeText("Word with Ruby \n") end word.DefaultSaveFormat word.Documents.close()