![]() |
【转帖】oddbole2frame
oddbole2frame
oddbole2frame hallo! i tried so much, but nothing worked: i would like to get the coleclientitem or the coledataobject from an oddbole2frame. in arx, there is the following available: code: coleclientitem* poleitem = (coleclientitem*)pole->getoleobject(); how can i do it with dwgdirect? thanks for any help or suggestion woho here is some of my code for when i retrieve data from the ole object and write out the compound document to a temporary file. odoleitemhandlerbase *ph; oddbole2frameptr pole; odbytedataptr pbytedata; // open the object so we can write to it pole->upgradeopen(); ph = (odoleitemhandlerbase *)pole->getitemhandler(); // place the binary data into the temporary file { odstreambufptr pbuf; pbuf = odsystemservices()->createfile(location, oda::kfilewrite, oda::ksharedenyreadwrite,oda::kcreatealways); pole->getcompounddocument (*pbuf); } hope this helps. quote: originally posted by woho hallo! ... in arx, there is the following available: code: coleclientitem* poleitem = (coleclientitem*)pole->getoleobject(); how can i do it with dwgdirect? thanks for any help or suggestion woho hi! odamfcapp example illustrates using of user-defined ole handler (it's implemented using coleclientitem and coledocument mfc classes). so there you can cast statically from odoleitemhandler to coleclientitem. please, see odamfcapp example (ole.cpp). thanks for your help. no, it works. the main problem was to get the ole-data to the coleclientitem. woho |
所有的时间均为北京时间。 现在的时间是 06:09 PM. |