2个回答
展开全部
Sub InsertRaster()
Dim a As AcadRasterImage
Dim b(2) As Double
Dim ly As AcadLayer
Dim PicFileName As String
Dim factor As Double
factor = 2#
Set ly = ThisDrawing.Application.ActiveDocument.Layers.Add("底图")
PicFileName = "E:\图片\Bliss.jpg"
b(0) = 100
b(1) = 100
b(2) = 0
Set a = ThisDrawing.Application.ActiveDocument.ModelSpace.AddRaster(PicFileName, b, factor, 45)
a.Transparency = True
a.Layer = "底图"
ThisDrawing.Application.ZoomExtents
ThisDrawing.SaveAs "E:\yangbiao.dwg"
End Sub
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询