怎样在程序中把图片写入到word中。 在vb中,怎样把图片写入到word中,同时还有文字。 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 转载功能是:在指定位置插入图片并设置图片的格式(包括设置为衬托于文字下 方)Sub 设置图片格式() Selection.InlineShapes.AddPicture FileName:="D:\Mypicture\800x600.jpg", _ LinkToFile:=False, SaveWithDocument:=True Selection.MoveLeft Unit:=wdCharacter, Count:=1, Extend:=wdExtend Selection.InlineShapes(1).ConvertToShape.Select Selection.ShapeRange.Fill.Visible = msoFalse Selection.ShapeRange.Fill.Transparency = 0# Selection.ShapeRange.Line.Weight = 0.75 Selection.ShapeRange.Line.DashStyle = msoLineSolid Selection.ShapeRange.Line.Style = msoLineSingle Selection.ShapeRange.Line.Transparency = 0# Selection.ShapeRange.Line.Visible = msoFalse Selection.ShapeRange.LockAspectRatio = msoTrue Selection.ShapeRange.Height = 361.4 Selection.ShapeRange.Width = 481.6 Selection.ShapeRange.PictureFormat.Brightness = 0.5 Selection.ShapeRange.PictureFormat.Contrast = 0.5 Selection.ShapeRange.PictureFormat.ColorType = msoPictureAutomatic Selection.ShapeRange.PictureFormat.CropLeft = 0# Selection.ShapeRange.PictureFormat.CropRight = 0# Selection.ShapeRange.PictureFormat.CropTop = 0# Selection.ShapeRange.PictureFormat.CropBottom = 0# Selection.ShapeRange.RelativeHorizontalPosition = _ wdRelativeHorizontalPositionColumn Selection.ShapeRange.RelativeVerticalPosition = _ wdRelativeVerticalPositionPage Selection.ShapeRange.Left = wdShapeCenter Selection.ShapeRange.Top = wdShapeCenter Selection.ShapeRange.LockAnchor = False Selection.ShapeRange.WrapFormat.AllowOverlap = True Selection.ShapeRange.WrapFormat.Side = wdWrapBoth Selection.ShapeRange.WrapFormat.DistanceTop = CentimetersToPoints(0) Selection.ShapeRange.WrapFormat.DistanceBottom = CentimetersToPoints(0) Selection.ShapeRange.WrapFormat.DistanceLeft = CentimetersToPoints(0.32) Selection.ShapeRange.WrapFormat.DistanceRight = CentimetersToPoints(0.32) Selection.ShapeRange.WrapFormat.Type = 3‘实际上真正有用的是下面的语句设置图片为衬托于文字下方 Selection.ShapeRange.ZOrder msoSendBehindTextEnd Sub 学习ing怎样来定位呢?比如说我想在文档的第三行、第三列加入图片,该如何处理? 高报酬寻VB高手做个PARTIME项目 (需要C#知识) 请教一下高手 网站来路分析的原理是什么? SQL语句出错,在线等待! 如何在VB Datareport报表中的工具栏上添加按钮!!!!!! 小弟提个问题。。。 mschar图形控件怎么联数据库啊,,具体,,, 数据库小问题!!!!!! 如何设置本机目录的共享属性? 另需下载功能的例子。 FarPoint Spread控件 我是送分的 怎样判断有向游戏那样的全屏幕程序在运行??急 ActiveX控件如何才能获取浏览器(打开的网页调用该控件)的地址(急!!,可加分)
功能是:在指定位置插入图片并设置图片的格式(包括设置为衬托于文字下 方)
Sub 设置图片格式()
Selection.InlineShapes.AddPicture FileName:="D:\Mypicture\800x600.jpg", _
LinkToFile:=False, SaveWithDocument:=True
Selection.MoveLeft Unit:=wdCharacter, Count:=1, Extend:=wdExtend
Selection.InlineShapes(1).ConvertToShape.Select
Selection.ShapeRange.Fill.Visible = msoFalse
Selection.ShapeRange.Fill.Transparency = 0#
Selection.ShapeRange.Line.Weight = 0.75
Selection.ShapeRange.Line.DashStyle = msoLineSolid
Selection.ShapeRange.Line.Style = msoLineSingle
Selection.ShapeRange.Line.Transparency = 0#
Selection.ShapeRange.Line.Visible = msoFalse
Selection.ShapeRange.LockAspectRatio = msoTrue
Selection.ShapeRange.Height = 361.4
Selection.ShapeRange.Width = 481.6
Selection.ShapeRange.PictureFormat.Brightness = 0.5
Selection.ShapeRange.PictureFormat.Contrast = 0.5
Selection.ShapeRange.PictureFormat.ColorType = msoPictureAutomatic
Selection.ShapeRange.PictureFormat.CropLeft = 0#
Selection.ShapeRange.PictureFormat.CropRight = 0#
Selection.ShapeRange.PictureFormat.CropTop = 0#
Selection.ShapeRange.PictureFormat.CropBottom = 0#
Selection.ShapeRange.RelativeHorizontalPosition = _
wdRelativeHorizontalPositionColumn
Selection.ShapeRange.RelativeVerticalPosition = _
wdRelativeVerticalPositionPage
Selection.ShapeRange.Left = wdShapeCenter
Selection.ShapeRange.Top = wdShapeCenter
Selection.ShapeRange.LockAnchor = False
Selection.ShapeRange.WrapFormat.AllowOverlap = True
Selection.ShapeRange.WrapFormat.Side = wdWrapBoth
Selection.ShapeRange.WrapFormat.DistanceTop = CentimetersToPoints(0)
Selection.ShapeRange.WrapFormat.DistanceBottom = CentimetersToPoints(0)
Selection.ShapeRange.WrapFormat.DistanceLeft = CentimetersToPoints(0.32)
Selection.ShapeRange.WrapFormat.DistanceRight = CentimetersToPoints(0.32)
Selection.ShapeRange.WrapFormat.Type = 3
‘实际上真正有用的是下面的语句设置图片为衬托于文字下方
Selection.ShapeRange.ZOrder msoSendBehindText
End Sub
怎样来定位呢?
比如说我想在文档的第三行、第三列加入图片,该如何处理?