- Oh no! An error has occurred!
- You need to be logged in to do that.
- You need to be logged in to do that.
- You need to be logged in to do that.
- You need to be logged in to do that.
- You need to be logged in to do that.
- You need to be logged in to do that.
- You need to be logged in to do that.
- You need to be logged in to do that.
- You need to be logged in to do that.
- You need to be logged in to do that.
- You need to be logged in to do that.
- You need to be logged in to do that.
- You need to be logged in to do that.
- You need to be logged in to do that.
- You need to be logged in to do that.
- You need to be logged in to do that.
-
Coinciding with the acquisition of VIA Development, Nate joined Autodesk in March of 2003 after a decade stint as an entrepreneur following a two-decade stint as a controls engineer and software applications developer at Owens-Corning. Nate is now the lead product architect for AutoCAD Electrical. He loves this stuff.
-
SS->PLC I/O utility - adding auto title block update - AutoCAD Electrical
August 13, 2007, 04:48 AM Nate HoltThe spreadsheet to PLC I/O generator tool is so tempting to modify and enhance that Autodesk supplies it to you in full source format (file name is c:\program files\autodesk\acade 2008\support\wdio.lsp). The tool allows you to define your project's PLC I/O requirements in an Excel spreadsheet and then, with a little configuration, AutoCAD Electrical will quickly generate a set of sequential drawings that document the I/O modules.
A number of users have adjusted this AutoLISP program to suit specific needs. One user suggestion came in last week: This utility generates new I/O drawings and can add them to your "active" AutoCAD Electrical project drawing set.

But the utilty does not auto-update each new sheet's title block as it is added. You have to go back and run AutoCAD Electrical's "title block update" utility. Why two steps?
Good question. Let's see if we can modify the wdio.lsp utility to auto-update the title block for each new drawing added to the active project.
STEP ONE
First, we need to find a command call that will update the active drawing's title block. Check the AutoCAD Electrical Help --> API Help topic. Poking around yields this promising candidate:

STEP TWO
Second, we need to open up the wdio.lsp utility (after making a back-up copy!) and figure out where we can insert this call. It should be at a point after the drawing is generated but before moving on to the next drawing (if the PLC I/O extends beyond a single sheet).
Open the file with a text editor or with AutoCAD's built-in Visual LISP editor (type vlide at command line). Here is a possible place in the program.

So we just type in the API call. It's shown below, the one line API call along with a bunch of comment lines:

STEP THREE
Save the revised version of wdio.lsp.
That's it. There's no compiling required. AutoCAD Electrical runs this particular tool straight from its text source file.
Select the SS->PLC I/O tool, make sure you toggle on the "Add drawings to active project", and test!
You must be logged in to post a comment.