A
Albus2
Hi to everybody ..
I have a problem with power point 2007
when i try to use the Paste method of
Microsoft.Office.Interop.PowerPoint.Shapes
it's return " Shapes (unknown member) : Invalid request. clipboard is empty
or contains data which may be not pasted here ".
The contents that i try to paste is an Html string, I post here my code:
using PowerPoint = Microsoft.Office.Interop.PowerPoint;
string html = @"Format:HTML Format
Version:1.0
StartHTML: 165
EndHTML: 444
StartFragment: 303
EndFragment: 412
StartSelection: 303
EndSelection: 303
<!DOCTYPE HTML PUBLIC ""-//W3C//DTD HTML 4.0 Transitional//EN"">
<HTML><HEAD><TITLE>From
Clipboard</TITLE></HEAD><BODY><!--StartFragment--><div>prispolo <img
src=""http://upload.wikimedia.org/wikipedia/en/b/b9/Alien3_poster.jpg""
alt="""" /></div><!--EndFragment--></BODY></HTML>";
Clipboard.Clear();
Clipboard.SetText(html, TextDataFormat.Html);
PowerPoint.ShapeRange spr = slide.Shapes.Paste();
This code work on ppt2003.
Thanks for attention.
I have a problem with power point 2007
when i try to use the Paste method of
Microsoft.Office.Interop.PowerPoint.Shapes
it's return " Shapes (unknown member) : Invalid request. clipboard is empty
or contains data which may be not pasted here ".
The contents that i try to paste is an Html string, I post here my code:
using PowerPoint = Microsoft.Office.Interop.PowerPoint;
string html = @"Format:HTML Format
Version:1.0
StartHTML: 165
EndHTML: 444
StartFragment: 303
EndFragment: 412
StartSelection: 303
EndSelection: 303
<!DOCTYPE HTML PUBLIC ""-//W3C//DTD HTML 4.0 Transitional//EN"">
<HTML><HEAD><TITLE>From
Clipboard</TITLE></HEAD><BODY><!--StartFragment--><div>prispolo <img
src=""http://upload.wikimedia.org/wikipedia/en/b/b9/Alien3_poster.jpg""
alt="""" /></div><!--EndFragment--></BODY></HTML>";
Clipboard.Clear();
Clipboard.SetText(html, TextDataFormat.Html);
PowerPoint.ShapeRange spr = slide.Shapes.Paste();
This code work on ppt2003.
Thanks for attention.