永利最大(官方)网站

永利最大(官方)网站 > 慧问 > 频道

为什么无法将图片导出到word,下为代码

发表于2019-05-10 回复:0 查看:2787  |  
string tmppath = Server.MapPath("~/image.doc"); Document doc = new Document(tmppath); //载入模板 #region 图片 DocumentBuilder builder = new DocumentBuilder(doc); Shape shape = new Shape(doc, ShapeType.Image); shape.ImageData.SetImage(Server.MapPath("~/Images/0.jpg")); shape.Width = 70; shape.Height = 70; shape.HorizontalAlignment = HorizontalAlignment.Right; //靠右对齐 builder.MoveToBookmark("image"); builder.InsertNode(shape); Bookmark myname = doc.Range.Bookmarks["image"]; myname.Text = ""; doc.Range.Bookmarks["image"].Remove(); doc.Save("demo.doc", SaveFormat.Doc, SaveType.OpenInWord, Response); #endregion
0个回答

打破零回复...

回复

登录 慧都网发表评论

扫码咨询


添加微信 立即咨询

电话咨询

客服热线
023-68661681

TOP
PM娱乐城网络现金网站(官方)网站/网页版登录入口/手机版登录入口-最新版(已更新) PM娱乐城最大(官方)网站/网页版登录入口/手机版登录入口-最新版(已更新) 永利外围最新(官方)网站/网页版登录入口/手机版登录入口-最新版(已更新) 网络权威朗驰娱乐大全(官方)网站/网页版登录入口/手机版登录入口-最新版(已更新) 永利真人网上足球(官方)网站/网页版登录入口/手机版登录入口-最新版(已更新) 利记最火十大网(官方)网站/网页版登录入口/手机版登录入口-最新版(已更新) boyu·博鱼权威网络足球(官方)网站/网页版登录入口/手机版登录入口-最新版(已更新) PM娱乐城网上足球(官方)网站/网页版登录入口/手机版登录入口-最新版(已更新)