open ZWCAD from Excel

Rank: 1

zw_admin

Newbie

posts: 0

Registered: 2012-1-14

Message 1 of 5

open ZWCAD from Excel
04-01-2012 08:29 . am | View his/her posts only
Hi,

I would like to be able to build a drawing in ZWCAD from Excel VBA. That would include the following steps:

1. Open ZWCAD if it is not already open
2. draw a line, polyline
3. draw solids (cube, sphere etc.)
4. save the drawing
5. export the content as SAT
6. close the application

Any suggestions, examples?

Thank you

Katto01
TOP 0 Kudos

Rank: 1

Stas

Newbie

posts: 0

Registered: 2012-1-12

Message 2 of 5

open ZWCAD from Excel
11-01-2012 10:46 . am | View his/her posts only
You neeed use COM object
Please look at this code fragment

Sub open_dwg()
Dim ZwCAD As ZwcadApplication
Dim frame As ZwcadDocument
Dim frameMSpace As ZwcadModelSpace

'create ZWCad Application
Set ZwCAD = CreateObject("ZwCAD.Application")
'open dwg-document
Set frame = ZwcadApplication.Documents.Open("'lib'frame.dwg")
'set model variable
Set frameMSpace = frame.ModelSpace;
'............
'
'insert here your function and code for adding object
'look at help for ModelSpace and adding objects
'
'............
End Sub
TOP 0 Kudos

Rank: 1

DDWZW

Newbie

posts: 144

Registered: 2011-11-23

Message 3 of 5

open ZWCAD from Excel
05-03-2012 03:33 . pm | View his/her posts only
does it help?
TOP 0 Kudos

Rank: 1

henlim

Newbie

posts: 1

Registered: 2011-12-10

Message 4 of 5

open ZWCAD from Excel
17-03-2012 12:24 . pm | View his/her posts only
i want to study it ,, how I get it ?,, Thanks
TOP 1 Kudos

Rank: 1

DDWZW

Newbie

posts: 144

Registered: 2011-11-23

Message 5 of 5

open ZWCAD from Excel
23-03-2012 11:03 . am | View his/her posts only
Reply 4# henlim


I want to learn how to
TOP 0 Kudos
© 2012 ZWCAD Software Co., Ltd. All rights reserved. | About ZWSOFT | Privacy Policy | Terms and Conditions | Contact us | Site Map
All trademarks,trade names or company names referenced herein are used for identification only and are the property of their respective owners.