开发者

Copy-Paste issue of smartArt in Powerpoint 2007/2010

开发者 https://www.devze.com 2023-03-28 12:54 出处:网络
I am working on powerpoint 2007/2010 in C++. I need to delete smart art objects of a smart art which is actually copied from original one.

I am working on powerpoint 2007/2010 in C++. I need to delete smart art objects of a smart art which is actually copied from original one. I use the following piece of code.

PPT::_SlidePtr pNewSlide=mDummyPresentation->Slides->Ad开发者_高级运维dSlide(1, PPT::ppLayoutBlank);
shp->Copy();
pNewSlide->Shapes->Paste();
PPT::ShapePtr pSmartArt=pNewSlide->Shapes->Item(1);
if(pSmartArt)
{
    long int counter = pSmartArt->GroupItems->Count;
    for(long int k = 0; k < counter; k++)
    {
        pSmartArt->GroupItems->Item(1L)->Delete();
    }
}

Issue I am facing is that I get count as zero even though the smart art has objects in it. If I code the same thing in VB, I face no issues. Could anyone please through some light on how to resolve the issue?

Thanks in advance, Holla

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号