![]() |
|
|
|||||||
![]() |
Microsoft Certification - Failed to get background of a slide |
|
|
Thread Tools | Search this Thread |
|
|
#1 |
|
Hi,
I have tried to insert a slide from one ppt to another ppt using the function InsertFromFile. But the background of the inserted slide is lost in the Destination ppt. How can I apply its "background" in the Destination ppt. Since it doesn’t work , I have find out an alternate solution. For each slide I have created a POT. And then that corresponding POT is applied to the inserted slide of the Destination ppt. But it works only if the background of the source ppt is “Applied to all the slides”. If the backround is “Applied to Selected slides” it doesn’t work. I have got a PPT ( SOURCEPPT.ppt), having slides with different design template having different background . For getting the design template of first slide , i have deleted the other slides of SOURCEPPT.ppt and saved it as SourceDesign.ppt and SourceDesign.pot. Now the SourceDesign.ppt contains a slide with template and background of first slide of the SOURCEPPT . I need that template with its background to be applied to all the slides of that PPT. I have tried , but its background is lost. How can I apply the background of one slide to all slides. Here is the code I have tried: CString strSourcePPT("D:\\Powerpoint\\SOURCEPPT.ppt"); Presentations presSource( m_ppt->GetPresentations() ); _Presentation SourcePres( presSource.Open( strSourcePPT, FALSE, FALSE, FALSE ) ); Slides SourceSlides( SourcePres.GetSlides() ); int nTotalSlide = SourceSlides.GetCount(); int nDelSlide = nTotalSlide; for(int nSlideCnt = 1; nSlideCnt < nTotalSlide; ++nSlideCnt) { _Slide DeleteSlide( SourceSlides.Item( COleVariant( (long)(nDelSlide) ))); DeleteSlide.Delete(); nDelSlide--; } SourcePres.Save(); SourcePres.SaveAs("D:\\Powerpoint\\ SourceDesign.ppt",1,1); SourcePres.SaveAs("D:\\Powerpoint\\ SourceDesign.pot ",1,1); SourcePres.Close(); //Applying template to all the slides of SourceDesign.ppt Presentations presDest( m_ppt->GetPresentations() ); _Presentation DestPres( presDest.Open("D:\\Powerpoint\\ SourceDesign.ppt ", FALSE, FALSE, FALSE ) ); DestPres.ApplyTemplate(“D:\\Powerpoint\\ SourceDesign.pot”); DestPres.Save(); DestPres.Close(); I also tried by creating a PPT with some slides, and manually I loaded the template “SourceDesign.pot”. Background of “SourceDesign.pot” is lost while it is applied to this PPT. Thanks in Advance Archana =?Utf-8?B?YXJjaGFuYXNy?= |
|
|
![]() |
| Thread Tools | Search this Thread |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Lost Desktop Custom Background | nacho | Software | 0 | 09-23-2009 11:01 PM |
| HELP! Can't get rid of desktop background | jc1357 | General Help Related Topics | 14 | 04-21-2008 01:46 PM |
| 10 Reasons why HD-DVD and Blu-Ray Have Already Failed | Black Locust | DVD Video | 69 | 07-01-2006 04:24 AM |
| Re: Brute Force Cracking Failed, No Vulnerable Blocks, DVD Decrypter | Martino | DVD Video | 8 | 02-01-2006 10:09 PM |
| background music for my silent home movie help | Ninip | DVD Video | 3 | 01-01-2006 12:49 AM |