AutoCAD Electrical Forum
Welcome to Autodesk’s AutoCAD Electrical Forums. Share your knowledge, ask questions, and explore popular AutoCAD Electrical topics.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

DWGDESC Value

8 REPLIES 8
Reply
Message 1 of 9
joechrobak
847 Views, 8 Replies

DWGDESC Value

Where is the the value for DWGDESC and sheet
or DD1 DD2 DD3 stored in ACADE 2007?
I wrote a VBA routine to obtain these values from a converted project and would like to place them to be used by the update title block functions.

Joe
8 REPLIES 8
Message 2 of 9
Anonymous
in reply to: joechrobak

You can retrieve the project information using some of the API calls
provided.

(ace_getactiveproject) returns the active project's name.

(c:ace_proj_data projname) returns a list of lists with all the data for
each drawing within the project. The values you are looking for will be in
this return.

All this information is held in the project's .wdp file if you can't use
these API calls to retrieve the information for any reason.

Pat Murnen


wrote in message news:5182405@discussion.autodesk.com...
Where is the the value for DWGDESC and sheet
or DD1 DD2 DD3 stored in ACADE 2007?
I wrote a VBA routine to obtain these values from a converted project and
would like to place them to be used by the update title block functions.

Joe
Message 3 of 9
joechrobak
in reply to: joechrobak

Pat when I open the WDP file with notepad
I see the drawing filemname in the file but not the other information

Joe
Message 4 of 9
joechrobak
in reply to: joechrobak

Pat
I guess what I am looking for
Is there an API call that I can stuff values to these variables
i.e. I have a routine that will read the value on the title block and I want to put that value into the DD1 DD2 DD3 values for the drawing.
Message 5 of 9
Anonymous
in reply to: joechrobak

The drawing descriptions are held in the .wdp file. I've reproduced a small
amount of the bottom end here with some comments. Before each drawing name
are the optional descriptions. Three equal signs precede the text. I've
added spaces here between them for clarity but there should be no spaces in
the .wdp file. The order of the liens tell which description it is, DD1,
DD2, or DD3.

=sec1
= =subsec1
= = =Flow and Interconnection diagram, I/O list
= = =Line 2 for drawing 1
= = =Line 3 for drawing 1
demo01.dwg
= = =3-phase motor control, Control circuit
= = =line 2 for drawing 2
= = =line 3 for drawing 2
demo02.dwg
= = =Power supplies, I/O module feeds
demo03.dwg
= = =Control schematic
demo04.dwg
= = =PLC I/O - Inputs - Slot 1
demo05.dwg
= = =PLC I/O - Inputs - Slots 3, 4
demo06.dwg
= = =PLC I/O - Input Slot 5, Output Slot 6
demo07.dwg
= = =Operator Station layout
demo08.dwg
= = =Main Control Panel layout
demo09.dwg

I didn't see any API specifically for this but you could look at the Help
under API section G - Project Management. It looks like some of these API's
weren't updated to include the newer description lines 2 & 3 though. For
example, wd_proj_wdp_write shows (list (list nil sec1 subsec1 dwg1 dwgdesc1
ref)(list nil sec2 subsec2 dwg2 dwgdesc2 ref)...) which doesn't include
support for the lines 2 & 3. I will log this.

Pat Murnen

wrote in message news:5182510@discussion.autodesk.com...
Pat
I guess what I am looking for
Is there an API call that I can stuff values to these variables
i.e. I have a routine that will read the value on the title block and I want
to put that value into the DD1 DD2 DD3 values for the drawing.
Message 6 of 9
joechrobak
in reply to: joechrobak

Pat
I was able to write the values to the WDP file for the Section
Sub-Section and DwgDescription
This seems to work fine for me.
What about theSheet # and Drawing under SHeet Values of Drawing proporties?
Where is this info stored?
Also, Can more User sheet values be added? i.e. Rev #and Rev Date etc..

When reading and writing to the WDP file are there any specific precautions to be aware of?

Thanks for your help

Joe
Message 7 of 9
Anonymous
in reply to: joechrobak

The Sheet and Drawing are saved on each drawing's WD_M block. This block
should be on each AcadE drawing and has quite a few attributes. The Sheet
value is stored on the SHEET attribute and the Drawing value is stored on
the SHEETDWGNAME attribute. There are some general API calls that can modify
an attribute value once you find the block.

The Rev# and Rev Date (or user-defined) aren't stored by AcadE. They could
be added as Drawing Custom Properties although depending on what you want to
do with these this may or may not help. If they are stored on your title
block, AcadE can update them with the Title Block function or report them
from the Drawing List report.

The .WDP file has a very specific format. It is not usually recommended to
modify it directly. But if you do modifiy it directly this format must be
maintained. Project description lines start with *[, default settings start
with ?[, specific project settings start with +[. Drawing information should
be at the end and is repeated for each drawing with the section line
starting with one equal sign, the sub-section 2 equal signs, and the drawing
descriptions 3 equal signs.

Pat Murnen

wrote in message news:5183406@discussion.autodesk.com...
Pat
I was able to write the values to the WDP file for the Section
Sub-Section and DwgDescription
This seems to work fine for me.
What about theSheet # and Drawing under SHeet Values of Drawing proporties?
Where is this info stored?
Also, Can more User sheet values be added? i.e. Rev #and Rev Date etc..

When reading and writing to the WDP file are there any specific precautions
to be aware of?

Thanks for your help

Joe
Message 8 of 9
110000474593
in reply to: joechrobak

Can you tell me how to acces te .wdp file trough VBA? I have a VBA script that puts some information in the drawing, and now I want to put some information in the drawing properties description 1.

 

Thank you.

Message 9 of 9
110000474593
in reply to: 110000474593

Never mind.

 

I've managed to add the descriptions to the drawing properties. In the Autodesk API Reference, section G - Project Management, there is a 'ace_add_dwg_to_project' function. With this function you can set 'Drawing Descriptions'.

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report

”Boost