/design.automation-.net-custom.activity.sample

C# sample to demonstrate Activities and AppPackages

Primary LanguageC#MIT LicenseMIT

Design Automation API v2 - C# sample: Create custom Activity and AppPackage

(Formely AutoCAD I/O)

.net odata ver visual studio License

##Description This is C# sample to demonstrate custom Activities and AppPackages creation. This is the most common use case that the Design Automation API can run the custom command (defined in the custom package) in the cloud.

##Dependencies

  • Visual Studio 2012, 2013 or 2015.
  • AutocAD 2017 (if you want to test your app locally)

##Setup/Usage Instructions

  • Build the solution (this will download dependencies from Nuget.org
  • Build project CrxApp. It is better to test with local AutoCAD to verify the process. Steps:
    • Open AutoCAD (in this test, the version is 2017)
    • Open demo drawing. Run command "netload", select the binary dll of CrxApp. Allow AutoCAD to load it.
    • Run command "test", select demo json file. Specify a output folder.
    • Finally the blocks name list and layers name list will dumped out.
  • Apply credencials of Design Automation API from https://developer.autodesk.com/. Put your consumer key and secret key at line 19 and 20 of program.cs
  • Run project Client, you will see a status in the console: []
  • if everything works well, some result files (pdf, zip) and the report files will be downloaded to MyDocuments.
  • if there is any error with the process, check the report file what error is indicated.

Please refer to Design Automation API v2 API documentation for more information such as how to setup a project.

Questions

Please post your question at our forum.

License

These samples are licensed under the terms of the MIT License. Please see the LICENSE file for full details.

##Written by

Jonathan Miao & Albert Szilvasy