Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/madhukarmoogala/fda_publishdsd
A CLI utility batch publish multiple drawings to single PDF using Forge Design Automation for AutoCAD
https://github.com/madhukarmoogala/fda_publishdsd
Last synced: 25 days ago
JSON representation
A CLI utility batch publish multiple drawings to single PDF using Forge Design Automation for AutoCAD
- Host: GitHub
- URL: https://github.com/madhukarmoogala/fda_publishdsd
- Owner: MadhukarMoogala
- License: mit
- Created: 2020-05-29T09:51:26.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2024-04-19T04:38:55.000Z (7 months ago)
- Last Synced: 2024-04-19T05:32:32.908Z (7 months ago)
- Language: C#
- Size: 23.8 MB
- Stars: 5
- Watchers: 3
- Forks: 3
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Design Automation for AutoCAD Application
[![Data-Management](https://img.shields.io/badge/Data%20Management-v1-green.svg)](http://developer.autodesk.com/)
[![Design-Automation](https://img.shields.io/badge/Design%20Automation-v3-green.svg)](http://developer.autodesk.com/)
[![netCore](https://img.shields.io/badge/netcore-3.1-green)](https://dotnet.microsoft.com/download/dotnet-core/current/runtime)
### Description
A CLI utility based on .NET Core technology to print multiple drawings in to a single pdf, the application logic in Bundle uses[PublishExecute](https://help.autodesk.com/view/OARX/2021/ENU/?guid=OARX-ManagedRefGuide-Autodesk_AutoCAD_Publishing_Publisher_PublishExecute_DsdData_PlotConfig) API
Uses [Forge Design Automation V3](https://forge.autodesk.com/en/docs/design-automation/v3)
### Design Automation
![WorkInDA](https://github.com/MadhukarMoogala/FDA_PublishDSD/blob/master/BatchPublishingWorks.gif)
### Prerequisites
1. **Forge Account**: Learn how to create a Forge Account, activate subscription and create an app at [this tutorial](http://learnforge.autodesk.io/#/account/).
2. **Visual Code**: Visual Code (Windows or MacOS)
3. **.netcore 3.1**: [dotnet core SDK](https://dotnet.microsoft.com/download/dotnet-core/current/runtime)
4. **7z** [7z Zip Archive](https://www.7-zip.org/download.html)
5. Make sure `7z.exe` is available on your system path env.`git clone https://github.com/MadhukarMoogala/FDA_PublishDSD`
### Instructions To Build AutoCAD Addin
```bash
cd BatchPublishCommand
msbuild BatchPublishCommand.csproj -property:Configuration=Debug;Platform=x64
```### Instructions To Build and Test Forge DA Client
```bash
cd BatchPublishCommand\client
notepad appsettings.users.json `feed with your Forge Credentials`
dotnet build
dotnet run -c RELEASE -i "" -o ""
```
`appsettings.users.json````
{
"Forge": {
"ClientId": "ForgeClientId",
"ClientSecret": "ForgeClientSecret"
}
}
````launchsettings.json`
```
{
"profiles": {
"ClientV3": {
"commandName": "Project",
"commandLineArgs": "-i \"C:\\Users\\moogalm\\Downloads\\exported.zip\" -o D:\\Work\\Arxprojects\\2020\\BatchPublishCommand\\output",
"workingDirectory": "..\\bin\\Release\\netcoreapp3.1",
"environmentVariables": {
"FORGE_CLIENT_SECRET": "ForgeClientId",
"FORGE_CLIENT_ID": "ForgeClientSecret"
}
}
}
}
```#### Instructions To Debug
##### .NETCore
```
edit launchsettings.json
launch ClientV3 profile.```
#### AutoCAD Addin`edit .csproj.user`
```
/s test.scr
Program
C:\Program Files\Autodesk\AutoCAD 2020\accoreconsole.exe
```
### Known Limitation
If the layout does not have an initialized page setup in drawings, this app will not be able to process, an error `no plottable sheets found` is thrown, the reason could be the drawings are from older versions of AutoCAD or from third-party applications.### How to Fix:
Open the file in AutoCAD and execute the PAGESETUP command on each layout to define it, which may simply entail modifying and then clicking OK, assuming the printer and other settings are correct.
As an alternative, within the Publish window, click the Page Setup pop-up menu on one of the layouts and choose *Import*. If a named page setup has been defined in another file, and is usable for the desired publish, it can be imported and applied to all the layouts in the sheet list.
### License
This sample is licensed under the terms of the [MIT License](http://opensource.org/licenses/MIT). Please see the [LICENSE](LICENSE) file for full details.### Written by
Madhukar Moogala, [Forge Partner Development](http://forge.autodesk.com) @galakar