For complete examples and data files, please go to https://github.com/aspose-words/Aspose.Words-for-C
System::SharedPtr<Document> doc = System::MakeObject<Document>();

System::SharedPtr<DocumentBuilder> builder = System::MakeObject<DocumentBuilder>(doc);
System::SharedPtr<Shape> shape = builder->InsertOleObjectAsIcon(inputDataDir + u"embedded.xlsx", false, inputDataDir + u"icon.ico", u"My embedded file");

doc->Save(outputDataDir + u"WorkingWithShapes.InsertOLEObjectAsIcon.docx");

std::cout << "The document has been saved with OLE Object as an Icon." << std::endl;