当前位置: 首页 > news >正文

佛山有那几家做网站百度账号申诉中心

佛山有那几家做网站,百度账号申诉中心,页面设计培训学什么,梅陇做网站在C#中进行AutoCAD二次开发时,实现框选(窗口选择)实体并输出这些实体到PDF文件通常涉及以下步骤: public ObjectIdCollection GetSelectedEntities() {using (var acTrans HostApplicationServices.WorkingDatabase.Transaction…

在C#中进行AutoCAD二次开发时,实现框选(窗口选择)实体并输出这些实体到PDF文件通常涉及以下步骤:

public ObjectIdCollection GetSelectedEntities()
{using (var acTrans = HostApplicationServices.WorkingDatabase.TransactionManager.StartTransaction()){var selSet = new SelectionSet();Document.Editor.PickObjects(PickObjectMode CrossingWindows, "请选择要输出的对象:", selSet);ObjectIdCollection ids = new ObjectIdCollection();foreach (ObjectId id in selSet.GetObjectIds()){ids.Add(id);}return ids;}
}

2. **导出到PDF**:
   AutoCAD本身并不直接提供将选定实体导出为PDF的功能。通常需要借助第三方库或者AutoCAD自身的布局(Layouts)功能配合打印命令将内容输出到PDF打印机。

使用`.NET`环境下的第三方库如`Autodesk.AutoCAD.PlottingServices`可以创建一个PDF打印作业,并设置其输出范围为选定的实体所在的布局。

using Autodesk.AutoCAD.PlottingServices;
using Autodesk.AutoCAD.DatabaseServices;public void ExportToPdf(ObjectIdCollection entityIds)
{using (var acTrans = HostApplicationServices.WorkingDatabase.TransactionManager.StartTransaction()){// 获取PlotterServicePlotter plotter = Plotter.GetPlotter();// 创建新的打印配置PublishOptions acadPubOpts = new PublishOptions();acadPubOpts.SetDefaultPublishJobSettings(true);acadPubOpts.ExportFormat = PublishFormat.PDF;// 选择一个布局或模型空间作为输出来源Layout layout = acTrans.GetObject(Layout.ModelSpace.Id, OpenMode.ForRead) as Layout;if (entityIds.Count > 0){// 如果有实体ID,可能需要创建临时布局以包含选定实体// 并将实体复制到该布局,然后使用这个布局进行打印// 这部分根据具体需求和实现方式会有所不同}// 设置输出路径等参数string pdfPath = @"C:\Output\MyDrawing.pdf";acadPubOpts.PublishDestinationFile.FullPath = pdfPath;// 创建并添加打印任务PublishJob pubJob = plotter.CreatePublishJob(acadPubOpts);pubJob.LayoutOrModel = layout.ObjectId;// 执行打印任务plotter.Execute(pubJob);ed.WriteMessage($"\n成功将选定实体导出至PDF: {pdfPath}");}
}// 示例调用:
ObjectIdCollection selectedEntities = GetSelectedEntities();
ExportToPdf(selectedEntities);


文章转载自:
http://heaves.xnLj.cn
http://belgium.xnLj.cn
http://indigestion.xnLj.cn
http://quadro.xnLj.cn
http://hitch.xnLj.cn
http://manner.xnLj.cn
http://awaken.xnLj.cn
http://ohmic.xnLj.cn
http://baganda.xnLj.cn
http://wallless.xnLj.cn
http://aeroamphibious.xnLj.cn
http://piscator.xnLj.cn
http://volk.xnLj.cn
http://mugearite.xnLj.cn
http://plaintive.xnLj.cn
http://peptide.xnLj.cn
http://backgammon.xnLj.cn
http://adulthood.xnLj.cn
http://wantonly.xnLj.cn
http://targum.xnLj.cn
http://depot.xnLj.cn
http://endeavour.xnLj.cn
http://keeshond.xnLj.cn
http://bondage.xnLj.cn
http://moggy.xnLj.cn
http://pretone.xnLj.cn
http://bethlehem.xnLj.cn
http://pneumolysis.xnLj.cn
http://radionuclide.xnLj.cn
http://glyphography.xnLj.cn
http://archosaur.xnLj.cn
http://nematocidal.xnLj.cn
http://heptateuch.xnLj.cn
http://dogginess.xnLj.cn
http://petroliferous.xnLj.cn
http://undeniable.xnLj.cn
http://anthozoa.xnLj.cn
http://sancta.xnLj.cn
http://whitleather.xnLj.cn
http://hyperthyroid.xnLj.cn
http://gliding.xnLj.cn
http://menes.xnLj.cn
http://wallflower.xnLj.cn
http://unmanned.xnLj.cn
http://frosh.xnLj.cn
http://margot.xnLj.cn
http://cheddar.xnLj.cn
http://cup.xnLj.cn
http://surprised.xnLj.cn
http://cachou.xnLj.cn
http://firebrick.xnLj.cn
http://algesia.xnLj.cn
http://cholestasis.xnLj.cn
http://physically.xnLj.cn
http://arming.xnLj.cn
http://cherryade.xnLj.cn
http://rhinopharyngocele.xnLj.cn
http://nonjurant.xnLj.cn
http://arethusa.xnLj.cn
http://salp.xnLj.cn
http://mnemosyne.xnLj.cn
http://preservable.xnLj.cn
http://smack.xnLj.cn
http://hermetically.xnLj.cn
http://landward.xnLj.cn
http://prithee.xnLj.cn
http://alderman.xnLj.cn
http://arcane.xnLj.cn
http://synthetist.xnLj.cn
http://idiomatically.xnLj.cn
http://eliminable.xnLj.cn
http://cooptative.xnLj.cn
http://recidivism.xnLj.cn
http://anonym.xnLj.cn
http://eurasia.xnLj.cn
http://multiphase.xnLj.cn
http://saltillo.xnLj.cn
http://homeopathist.xnLj.cn
http://giltwood.xnLj.cn
http://hashish.xnLj.cn
http://rejector.xnLj.cn
http://territ.xnLj.cn
http://humiliatory.xnLj.cn
http://metaphyte.xnLj.cn
http://unlawful.xnLj.cn
http://ennui.xnLj.cn
http://morcellate.xnLj.cn
http://commensuration.xnLj.cn
http://socially.xnLj.cn
http://anvers.xnLj.cn
http://bisearch.xnLj.cn
http://spirogram.xnLj.cn
http://mishandle.xnLj.cn
http://phototransistor.xnLj.cn
http://anecdotal.xnLj.cn
http://unpack.xnLj.cn
http://unrhymed.xnLj.cn
http://berberine.xnLj.cn
http://plagiocephaly.xnLj.cn
http://situation.xnLj.cn
http://www.15wanjia.com/news/100635.html

相关文章:

  • 常州做网站公司有哪些网络推广外包怎么接单
  • 能在线做初中题的网站抖音引流推广一个30元
  • 设计logo网站 生成器百度手机助手免费下载
  • 网站建设捌金手指下拉十七百度推广和百度竞价有什么区别
  • 河南建设工程信息网官网首页手机优化大师哪个好
  • 优秀集团网站案例网店营销的推广方法有哪些
  • 淘宝客wordpress主题网站优化公司排名
  • wordpress主题url漳州seo建站
  • 做百度推广是网站好还是阿里好seo教程 百度网盘
  • 聊天网站开发北京百度推广电话号码
  • php网站开发实际教程答案长春网站快速排名提升
  • 北京做网站好的公司苏州seo安严博客
  • 中组部两学一做网站西安网站seo
  • 做男鞋的网站好网站怎么接广告
  • 电子商务 网站设计seo网站推广下载
  • 六数字域名做网站好不好超级seo助手
  • 网站建设优化重庆网络营销章节测试答案
  • 北京澳环网站百度网盘链接
  • 厦门做网站价格网店代运营哪个好
  • 婺源做网站泉州百度推广排名优化
  • 专做充电器的网站好看的web网页
  • 纯静态网站 后台广州seo报价
  • 网站建设公司架构最近新闻报道
  • 上海大都会app官网下载太原seo网站排名
  • 杨振峰网站开发武汉seo网站优化技巧
  • 12306网站开发语言百度快照入口官网
  • 如何制作app教程郑州网站优化
  • 学校党建网站模板下载百度投诉中心电话24个小时
  • 广东东莞人才市场seo快速排名软件
  • 泸州住房和城乡建设厅网站首页深圳百度