Creating new drawing file.

Creating new drawing file.

Anonymous
Not applicable
1,393 Views
4 Replies
Message 1 of 5

Creating new drawing file.

Anonymous
Not applicable

Hi,

 

How I can create new drawing(.dwg) file using drawing template(.dwt)file in back end (Means with out showing in front end).

 

Thanks in advance...

 

Regards,

Rama

 

0 Likes
Accepted solutions (2)
1,394 Views
4 Replies
Replies (4)
Message 2 of 5

Alfred.NESWADBA
Consultant
Consultant

Hi,

 

if you want to create a new database (so you don't open it in the AutoCAD-Editor) you can use:

Public Sub New(buildDefaultDrawing As Boolean, noDocument As Boolean)
     Member von Autodesk.AutoCAD.DatabaseServices.Database

 

HTH, - alfred -

------------------------------------------------------------------------------------
Alfred NESWADBA
ISH-Solutions GmbH / Ingenieur Studio HOLLAUS
www.ish-solutions.at ... blog.ish-solutions.at ... LinkedIn ... CDay 2026
------------------------------------------------------------------------------------

(not an Autodesk consultant)
Message 3 of 5

Anonymous
Not applicable

Thanks for your response...

 

 

Please tell me how can use tempalate in this statement

 

Regards,

Raman

0 Likes
Message 4 of 5

Alfred.NESWADBA
Consultant
Consultant
Accepted solution

Hi,

 

>> Please tell me how can use tempalate in this statement

You can insert your template (or parts of it) in the new database (using WBLOCKCLONEOBJECTS or simililar funcionality).

You can also create a new database and do then DatabaseObj.ReadDwgFile to get the template-data into the new database-object and then -SaveAs to a new DWG.

 

- alfred -

------------------------------------------------------------------------------------
Alfred NESWADBA
ISH-Solutions GmbH / Ingenieur Studio HOLLAUS
www.ish-solutions.at ... blog.ish-solutions.at ... LinkedIn ... CDay 2026
------------------------------------------------------------------------------------

(not an Autodesk consultant)
0 Likes
Message 5 of 5

Alexander.Rivilis
Mentor
Mentor
Accepted solution

db.ReadDwgFile("<path to template file>",...)

Відповідь корисна? Клікніть на "ВПОДОБАЙКУ" цім повідомленням! | Do you find the posts helpful? "LIKE" these posts!
Находите сообщения полезными? Поставьте "НРАВИТСЯ" этим сообщениям!
На ваше запитання відповіли? Натисніть кнопку "ПРИЙНЯТИ РІШЕННЯ" | Have your question been answered successfully? Click "ACCEPT SOLUTION" button.
На ваш вопрос успешно ответили? Нажмите кнопку "УТВЕРДИТЬ РЕШЕНИЕ"


Alexander Rivilis / Александр Ривилис / Олександр Рівіліс
Programmer & Teacher & Helper / Программист - Учитель - Помощник / Програміст - вчитель - помічник
Facebook | Twitter | LinkedIn
Expert Elite Member

0 Likes