PDA

View Full Version : insertcaption in word using activeqt



ivareske
30th March 2011, 12:59
Has anyone been able to insert a caption in a word document? I`m able to create the document and obtain selections. I have managed to insert text, paragraphs, tables and changing the font, but I can`t get the InsertCaption to work.

http://msdn.microsoft.com/en-us/library/aa212219(v=office.11).aspx

I have tried amongst others

selection_->dynamicCall("InsertCaption(const QVariant&,const QVariant&,const QVariant&,const QVariant&,const QVariant&","Label","title","","wdCaptionPositionBelow",0); //and
selection_->dynamicCall("InsertCaption(Label,TitleAutoText,Title,Position,E xcludeLabel",label,title,"","wdCaptionPositionBelow",false);

The selection object is valid, I have as mentioned managed to other stuff with it.

-Ivar