Sub OpenDocx As JavaObject
Dim in As InputStream = File.OpenInput(dir, filename)
Dim document As JavaObject
Try
document.InitializeNewInstance("org.apache.poi xwpf.usermodel.XWPFDocument", Array(in))
Return document
Catch
fx.Msgbox(Null,LastException.Message,"Error")
Log(LastException.Message)
End Try
End Sub