C#CAD环境下DWG转PDF使用命令

更新时间:2023-05-17 22:30:34 阅读: 评论:0

C#CAD环境下DWG转PDF使⽤命令CAD环境下DWG转PDF
sherry什么意思Private Sub Button2_Click(nder As Object, e As EventArgs) Handles Button2.Click
Dim f As FileInfo = New FileInfo("E:\j9-FwfeplGMIpixSqiD9d.dxf")
Dim f1 As FileInfo = New FileInfo("E:\[3500×0×2][数量10](1).dxf")
'Dim f2 As FileInfo = New FileInfo("E:\j9-FwfeplGMIpixSqiD9d.dxf")
illusions'Dim f3 As FileInfo = New FileInfo("E:\j9-FwfeplGMIpixSqiD9d.dxf")
Dim list = New List(Of FileInfo)()兴奋用英语怎么说
list.Add(f)
list.Add(f1)
Dwg2Pdf(list)
End Sub
Public Shared Sub Dwg2Pdf(ByVal files As List(Of FileInfo))
Dim doc As AcadDocument = Nothing
Dim destPath As String = String.Empty
'InitializationApp()
Dim activeDoc As Document = Application.DocumentManager.MdiActiveDocument
'Dim ThisDrawing As AcadDocument = CType(activeDoc.AcadDocument, AcadDocument)
宝马英文缩写Try
For Each f In files
'doc = _app.Documents.Open(f.FullName, True)
doc = Application.DocumentManager.Open(f.FullName, True).AcadDocument
'doc = ThisDrawing.Open(f.FullName, True)
'ThisDrawing.LoadShapeFile(f.FullName)
'doc = ThisDrawingibelieve是什么意思
doc.SetVariable("sdi", 0)中国式英语
doc.SetVariable("Filedia", 0)
chineculture
doc.SetVariable("RASTERPREVIEW", 1)
baadoc.SetVariable("BACKGROUNDPLOT", 0)
doc.ActiveLayout.ConfigName = "DWG To PDF.pc3"
doc.ActiveLayout.UStandardScale = True
doc.ActiveLayout.StandardScale = AcPlotScale.acScaleToFit
doc.ActiveLayout.PlotType = AcPlotType.acExtentsdfm
doc.ActiveLayout.CenterPlot = True
doc.ActiveLayout.PlotRotation = AcPlotRotation.ac0degrees
doc.ActiveLayout.PlotType = Autodesk.AutoCAD.Interop.Common.AcPlotType.acExtents
according todoc.Plot.QuietErrorMode = True
destPath = Path.Combine(f.Directory.FullName, Path.GetFileNameWithoutExtension(f.Name) & ".pdf")
doc.Plot.PlotToFile(destPath)
If doc IsNot Nothing Then doc.Clo(Fal)
Next
Catch e As System.Exception
Throw e
Finally
Try
doc.Clo(Fal)
_app.Quit()
Catch
End Try
End Try
End Sub

本文发布于:2023-05-17 22:30:34,感谢您对本站的认可!

本文链接:https://www.wtabcd.cn/fanwen/fan/78/673355.html

版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。

标签:环境   命令
相关文章
留言与评论(共有 0 条评论)
   
验证码:
推荐文章
排行榜
Copyright ©2019-2022 Comsenz Inc.Powered by © 专利检索| 网站地图