// Make sure that the insertion fails: // 1) the user explicitly requested that the data is not loaded into Writer // 2) this is non-Windows, so OLE embedding is not an option // so silently still loading the data into Writer would be bad.
CPPUNIT_ASSERT(!xObject.is());
}
// Make sure that the insertion fails: // 1) the user explicitly requested that the data is not loaded into Writer // 2) this is non-Windows, so OLE embedding is not an option // so silently still loading the data into Writer would be bad.
CPPUNIT_ASSERT(!xObject.is());
}
// Insert a PDF file as an embedded object.
uno::Reference<embed::XStorage> xStorage = comphelper::OStorageHelper::GetTemporaryStorage();
comphelper::EmbeddedObjectContainer aContainer(xStorage);
OUString aFileName = createFileURL(u"insert-file-config.pdf");
uno::Sequence<beans::PropertyValue> aMedium{ comphelper::makePropertyValue(u"URL"_ustr,
aFileName) };
OUString aName(u"Object 1"_ustr);
uno::Reference<embed::XEmbeddedObject> xObject
= aContainer.InsertEmbeddedObject(aMedium, aName);
// Make sure that the insertion fails: // 1) the user explicitly requested that the data is not loaded into Writer // 2) this is non-Windows, so OLE embedding is not an option // so silently still loading the data into Writer would be bad.
CPPUNIT_ASSERT(!xObject.is());
}
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.