View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Mohan Mohan is offline
external usenet poster
 
Posts: 22
Default Inserting .dwg file in excel opens the drawing in autocad...


Hi All
when I try to insert .dwg file in excel using oleobjects add method it opens
the drawing in autocad and inserts blank space for the image the code which i
an using is as under..


ExcelWorksheets sheets = book.GetWorksheets();
_ExcelWorksheet s;

lpDisp3 = oExcel.GetActiveSheet();
ASSERT(lpDisp3);
s.AttachDispatch(lpDisp3);
//filename = D:\test.dwg;
OLEObjects ole = s.OLEObjects(covOptional);
ole.Add(covOptional,(COleVariant)filename,
covFalse,covFalse,covOptional,covOptional,covOptio nal,covOptional,covOptional,covOptional,covOptiona l);

Also i am using excel8.h and excel8.cpp files to get the objects of
woorksheet and workbooks

any help will be greatfull

--
mohan