Message 1 of 3
Python connexion with AutoCad
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Dear,
I would like to try python automation with AutoCAD so I downloaded the trial version of AutoCad which is named : Autodesk AutoCAD 2026 - UNREGISTERED VERSION.
However, I cannot connect python with autocad. I get the following error message : OSError: [WinError -2147221005] running the code bellow.
Could you please tell me if python automation is supported with this version of AutoCAD ?
NB : I don't have admin rights on my laptop, I ran python file with both vscode and cmd
Kind regards,
Adrien
Code :
import pyautocad
acad = pyautocad.Autocad()
print(acad.doc.Name)