Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations waross on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

Revision blocks

Status
Not open for further replies.

dogarila

Mechanical
Oct 28, 2001
594
CA
My company has purchased SW for several months and we are trying to shift the 2d drawings from AutoCAD to SW. It's hard because our AutoCAD is highly customized and the designers and detailers are not happy to give up all the facilities I created for them in AutoLISP. One of the little problem we encountered is how to provide a simple method in introducing and updating the revision block and revision notes in the drawings.

In AutoCAD, I created an AutoLISP routine which opened up a dialog box, filled up the date, revision number (next available), person who was doing the revision (as rhe person who was logged in to that computer) and offered up to ten lines to describe the revision. When "OK" button was clicked it created a block with attributes entered on the dialog box, created all the necessary geometry, inserted itself in the proper position and updated the title block with the new revision number.

I would like to create something similar in SW. Anybody has any thoughts or suggestions about how to approach this problem?

Thanx
Netshop21
 
Replies continue below

Recommended for you

We are doing something pretty simular here. We are accomplishing this through visual basic. We have automated a quite a bit in SolidWorks through visual basic and visual basic script. BBJT CSWP
 
Netshop21,

I have also done quite a bit in this area. I started with a VB program that was originally writen for Solid Edge to do just exactly what you want. I modified the program so it would automatically detect which CAD package was running and adjust as needed.

Some of the fields that required data were; Part number, description, material, density, finish, heat treat, lead engineer, designer, and checker. For entries where there could be multiple entries such as "where used" and revisions, I added a list box for each. For the revision information, the fields were; ECN number, date, engineer/designer, checker, and description. The description field was limitless in length. The program would automatically adjust the width of the note field in SolidWorks, and SolidWorks would automatically change the height. The program would then look to see what the height of the note was and adjust for the next note.

All information was stored in "file properties". For the revisions and where used, using Solid Edge, those were in the custom properties. If using SolidWorks, all of the previously mentioned fields were in the custom properties area. This made it much easier to incorporate new columns into a BOM. I used a special character to indentify which was which. I used chr(30) for the "where used", and chr(31) for the revisions. So revision "A" would be stored with the property name chr(31)&"A". The program would search through all of the custom properties. If either of the special characters were found, the program knew what to do with them.

I'm in the process of writing a SolidWorks macro to do almost the exact same thing that the VB program did. I have the VB program here (at my new job) and I'm gutting as much useful code as I can for this new macro. I may post the new macro for everyone, if I ever get enough time to finish it.

I've been told that a PDM package will handle this problem. The down side is that you have to learn another tool and then maintain it, and deal with the MIS/IT people of your company, etc., etc., etc...
Don Shoebridge
Sr. Product Developement Engineer
 
BBJT,

can you give me some hints about what you did so far about this revision problem?

Don,
is it possible to send me the VB program you were talking about? My email address is (again) : andrew@netshop21.com.

Many thnx to both of you,

Andrew
 
Andrew,

I'm in the process of moving to Wabash, Indiana from Dayton, OH. I'll send you something by next weekend. I'm have to make a new program because of differences in company policies concerning engineering activities. The down side is that I don't have Visual Basic, so I'm having to write this new batch of code as a SolidWorks macro. Due to an oversight, and my lack of experience using the VB macro environment within SolidWorks, I've already completly lost my new program. So I'll have to start over. I'd would rather send you this new program because it is going to be much easier to pick through and modify if necessary. It wiil handle revisions, where used, and configurations when complete.

One reason that I lost the new program isthat I couldn't get it to execute within SolidWorks. If I were to run it from the VB editor, it would function just fine. This macro/program had multiple sub routines and a form. When I ran it from SolidWorks, nothing would happen. It was like SolidWorks couldn't find the "Main" sub routine. Does anyone have any advice?
Don Shoebridge
Sr. Product Developement Engineer
 
netshop21,

I have just finished writting such a VB program to handle just this problem and are in the process of testing it. It will be available to Solidworks users via the HOUSUG Users group. Additionally there are a numerous of cool tools that I have written to enhance the solidworks users productivity.
 
I am new to this site and just came across this thread discussing automating the process to insert revision data in a SW drawing. I realize this thread has ben around for awhile but I would be very interested in getting info on this either by using VB or a SW macro.

Thanks

Steve Ray
 
3DDon,

Which version of SW are you using? Prior to SW2003, Sub Main had to be the last sub in the macro. Since you have a form, I would move all procedures to the form and put Form1.Show (substitute the name of your form for Form1) in Sub Main(). This is how I have gotten around the problem you describe in the past.

Regg
 
I am trying to set up our company with a standard drawing template that will add data to the revison block on the drawing template. Was the above mentioned files ever put up for general use on any sites?

Thanks

Mary
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top